> create 2 variables in your main.prg
>
> public abc, cba
>
>
> when you index your tables use this variables like :
>
>
> use acchead
> index on head for abc=cba tag head
>
>
> now try to use this file from outside of the programme
>
> this will give you error "variable cba not found"
>
> warm regards
> mk.
MK,
I do not really think that introducing an error into the table is the best way to accomplish database security. There are a number of other solutions that solve this Ahsan's problem better. For that matter, he might be better off to simply create a log showing who modified what record and when. I do this for some of my more sensitive data. I use insert and update triggers to insert the record to a similar table on another database. The table in the other database shows me every iteration of that record as it is saved. If a field value changes from a 1 to a 2 and then back to a 1, I will see three records showing what that record looked like when it was saved. All of my tables have an nUserID field and a tLastMod field, so I can track who did what to each record and I can even tell you when it was done.
Ken
You shall know the truth - and the truth shall set you free. (John 8:33)