Zac Spitzer wrote:
> Kay Smoljak wrote:
> |
> | A tip I picked up from somewhere - it might even have been this list
> | - is to not ever actually delete records using code. Instead, I have
> | a dtDeleted field, which is set to the current date when I want to
> | delete the record. When doing selects, I add "WHERE dtDeleted IS
> | NULL" to get only non-deleted records.
> |
> 
> good idea, badly implemented..... a select using a null criteria cannot
> use a index and means the database must do a full table scan which means
> ~ bad performance....try changing your logic round so you can use an
> index...

That is just a limitation of your specific dbms. Others can use much 
fancier indexing schemes. (If your database supports it, look into 
partial indexes for this type of problem.)

Jochem

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to