[eluser]Madmartigan1[/eluser]
Hi guys,
In most of my database tables, I use a field called 'active' for when a user 'deletes' a record.
TINYINT, DEFAULT 1
0 = deleted
1 = not deleted
The sql to select the records will always have 'WHERE active=1', unless for some reason I'm displaying 'deleted' data.
I know this is splitting hairs, but I was wondering if it might be better to use a field called 'deleted' with a default of 0. Is it better to use 'WHERE active != 0' with the first method? It probably makes no difference.
What do you guys usually do? Is there a standard for this technique?