General information
Category:
Databases,Tables, Views, Indexing and SQL syntax
>>Hi
>>
>>I have a table that contains 192,216 records, 177,493 of these are deleted records.
>>
>>I have a DELETED() Index on the table, yet when I run a command like SCAN FOR...ENDSCAN on an indexed field, it takes absolutely ages. This is over a 1MB WAN by the way, but it still should only take seconds, it takes minutes, about 3 to be exact.
>>
>>What am I doing wrong here?
>>
>>Thanks
>>Kev
>
>You should avoid two things:
>
>1) Having ca. 90% of the records deleted. Plan a PACK at least once a month; more frequent depending on the amount of changes done. You can create an automated procedure that will do this at midnight.
Yes, an overnight run has been failing, so I'm on that now.
>2) Having an index on DELETED(). This can actually slow things down. See my FAQ on "Rushmore" for details.
I'll have a read.
Thanks
Kev
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only