After inserting, modifying, or deleting a large amount of records in a table that contains indexes performance of queries can be increased by use of the update statistics query. The update statistics query creates or replaces statistics on a column and stores them in the system tables systabstats and sysstatistics. Sybase utilizes these statistics when determining how to process a query.
Examples:
Updating all indexes of a Table
update statistics T_USERS -- T_USERS = table name
Updating a single index of a Table
update statistics T_USERS user_pk_idx -- user_pk_idx = index name
Comments & Questions
Add Your Comment