Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. sponsors. rss.
 From: Ken Murphy
  Where is Ken Murphy?
 Springhill
 Canada
 Ken Murphy
 To: mk sharma
  Where is mk sharma?
 mumbai
 India
 mk sharma
 Tags
Subject: RE: Data Base Security
Thread ID: 120452 Message ID: 125833 # Views: 87 # Ratings: 0
Version: Visual FoxPro 7 Category: Databases, Tables and SQL Server
Date: Thursday, March 15, 2007 10:39:44 PM         
   


> if some one add records from BROWSE with CTRL+Y
>
> how we can track that records.
>
> warm regards,
> mk.
>
>
> > > 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)

MK

Tushar is quite correct about triggers. This is what I use for my sensitive tables. There are a number of advantages to triggers, not the least of which is that your triggers work regardless of how the insert/update/delete is done. If you modify the data using your app, you need not change any of the app code. If you develop another app that uses this same data, you do not have to incorporate any new code. If you access the table using a browse window or even using somebody else's software, the trigger still works. The real advantage to triggers is that you can use them to inforce referential integrity. If you are not familiar with the use of stored procedures and triggers, I recommend that you set aside some time and play with them.

Ken
You shall know the truth - and the truth shall set you free. (John 8:33)



COMPLETE THREAD
Data Base Security Posted by Ahsan Rana @ 2/1/2007 8:45:45 AM
RE: Data Base Security Posted by tushar @ 2/1/2007 8:59:56 AM
RE: Data Base Security Posted by Ahsan Rana @ 2/1/2007 12:38:58 PM
RE: Data Base Security Posted by Ken Murphy @ 2/1/2007 1:41:30 PM
RE: Data Base Security Posted by suhas hegde @ 12/20/2007 3:31:55 PM
RE: Data Base Security Posted by Frank Cazabon @ 2/1/2007 1:47:50 PM
RE: Data Base Security Posted by Boudewijn Lutgerink @ 2/1/2007 5:34:56 PM
RE: Data Base Security Posted by Ken Murphy @ 2/1/2007 5:44:05 PM
RE: Data Base Security Posted by Boudewijn Lutgerink @ 2/1/2007 5:46:21 PM
RE: Data Base Security Posted by Daniel Hofford @ 8/26/2007 3:22:47 PM
RE: Data Base Security Posted by William Sanders @ 12/19/2007 6:08:03 PM
RE: Data Base Security Posted by Andy Kramek @ 2/1/2007 11:37:49 AM
RE: Data Base Security Posted by meid lababidi @ 2/1/2007 2:47:49 PM
RE: Data Base Security Posted by Ken Murphy @ 2/1/2007 3:33:42 PM
RE: Data Base Security Posted by Tariq mehmood @ 2/6/2007 4:49:21 PM
RE: Data Base Security Posted by Boudewijn Lutgerink @ 2/7/2007 10:44:54 AM
RE: Data Base Security Posted by Tariq mehmood @ 2/7/2007 1:37:03 PM
RE: Data Base Security Posted by Ken Murphy @ 2/7/2007 2:18:30 PM
RE: Data Base Security Posted by randy loberiano @ 2/27/2008 4:05:13 AM
RE: Data Base Security Posted by Pete Sass @ 2/2/2007 3:24:02 AM
RE: Data Base Security Posted by Bernard Bout @ 2/2/2007 4:18:42 AM
RE: Data Base Security Posted by Pete Sass @ 2/10/2007 7:14:25 PM
RE: Data Base Security Posted by Bernard Bout @ 2/14/2007 5:26:58 AM
RE: Data Base Security Posted by Jamie Osborn @ 3/15/2007 1:06:09 AM
RE: Data Base Security Posted by Naomi Nosonovsky @ 3/15/2007 3:50:17 AM
RE: Data Base Security Posted by Jamie Osborn @ 3/15/2007 3:51:16 AM
RE: Data Base Security Posted by Bernard Bout @ 3/15/2007 9:15:03 AM
RE: Data Base Security Posted by Pete Sass @ 3/15/2007 1:05:09 PM
RE: Data Base Security Posted by Bernard Bout @ 3/15/2007 2:32:10 PM
RE: Data Base Security Posted by Frank Cazabon @ 3/15/2007 7:49:19 PM
RE: Data Base Security Posted by suhas hegde @ 12/19/2007 5:16:28 PM
RE: Data Base Security Posted by Prasad Sakharkar @ 2/2/2007 7:33:51 AM
RE: Data Base Security Posted by Ravi Taxali @ 2/5/2007 9:30:25 PM
RE: Data Base Security Posted by kenan cejvan @ 2/5/2007 1:27:00 PM
RE: Data Base Security Posted by mk sharma @ 3/14/2007 5:35:09 PM
RE: Data Base Security Posted by Ken Murphy @ 3/14/2007 7:26:26 PM
RE: Data Base Security Posted by mk sharma @ 3/15/2007 8:16:54 AM
RE: Data Base Security Posted by tushar @ 3/15/2007 8:29:02 AM
RE: Data Base Security Posted by mk sharma @ 3/15/2007 8:45:45 AM
RE: Data Base Security Posted by tushar @ 3/15/2007 10:45:57 AM
RE: Data Base Security Posted by Ulhas Amrite @ 8/25/2007 10:46:23 AM
RE: Data Base Security Posted by tushar @ 8/25/2007 1:18:26 PM
RE: Data Base Security Posted by Ken Murphy @ 3/15/2007 10:39:44 PM
RE: Data Base Security Posted by Ulhas Amrite @ 8/31/2007 1:31:44 PM
RE: Data Base Security Posted by Ken Murphy @ 8/31/2007 2:30:32 PM
RE: Data Base Security Posted by Jamie Osborn @ 3/15/2007 1:40:16 AM
RE: Data Base Security Posted by Bernard Bout @ 3/16/2007 2:32:21 PM
RE: Data Base Security Posted by vivek deodhar @ 8/22/2007 5:53:35 PM
RE: Data Base Security Posted by Bernard Bout @ 8/22/2007 11:40:41 PM
RE: Data Base Security Posted by vivek deodhar @ 8/23/2007 6:36:34 AM
RE: Data Base Security Posted by vivek deodhar @ 8/23/2007 9:41:35 AM
RE: Data Base Security Posted by Bernard Bout @ 8/23/2007 10:33:37 PM
RE: Data Base Security Posted by vivek deodhar @ 8/25/2007 7:16:50 AM
RE: Data Base Security Posted by Bernard Bout @ 8/27/2007 6:42:08 AM
RE: Data Base Security Posted by vivek deodhar @ 2/27/2008 5:31:57 AM
RE: Data Base Security Posted by Bernard Bout @ 2/29/2008 6:24:47 AM
RE: Data Base Security Posted by Binod Binani @ 3/15/2007 7:03:46 PM
RE: Data Base Security Posted by Kip Dole @ 12/18/2007 4:42:43 PM
RE: Data Base Security Posted by Bernard Bout @ 12/19/2007 5:53:27 AM
RE: Data Base Security Posted by Cetin Basoz @ 12/19/2007 11:40:39 AM
RE: Data Base Security Posted by Joe Estrella @ 1/9/2008 8:37:27 AM