Information générale
Catégorie:
Codage, syntaxe et commandes
>>>Hate this "marked for deletion" crap. I come from an SQL environment that when you deleted a record, it was gone. If you wanted to mark records for deleteion, you added a delete flag column to your table. We never allow our clients to see deleted records, and they never have the opportunity to undelete. Yet they have to run a pack and reindex periodically.
>>>
>>>Is there a way to truly (madly, deeply) delete records from a table?
>>>
>>>Brenda
>
>>If you want the record gone, but can't take the hit of grabbing the file with an exclusive lock, just blank the record, then delete it and set deleted on. Be aware that set deleted doesn't impact sql queries unless you add the where not deleted() into the select statement.
>
>>After you blank the records and since they are marked for deletion you can pack the table later.
>
>What does blanking the record in a table that has unique indexes do? Part of what prompted my "crap" outburst is that I want to add unique indexes to our production tables. This would enforce uniqueness. But none of our updating code reuseses deleted records. We have many duplicate records in our tables (one deleted, one not deleted). In code we totally ignore deleted records. It would be an impossible task for me to rewrite all the undate code, so it is impossible for me to add unique indexes to our tables.
>
>Brenda
I thought unique indexes were something to be avoided at all costs...
-Michelle
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement