Error 2574

Severity

16

Message text

Versions earlier than 15.0:

Index page number %ld is empty.  Status = 0x%x.

Version 15.0 and later:

Index page number %d, partition ID %d, is empty. Status = 0x%x

Explanation

Tables can contain text columns, which are variable-length columns that can hold printable characters, and image columns, which are variable-length columns that can hold binary data. Adaptive Server stores text and image data in a linked list of data pages separate from the rest of the table. Each 2K text or image page stores a maximum of 1800 bytes of data.

Error 2574 occurs when a dbcc check finds problems with a page that is part of a table's text or image page chain. Error 7105 is a related error; it is raised when Adaptive Server attempts data retrieval or another operation on a table with a bad text or image page chain.

Action

Error 2574 is typically due to a small number of bad rows in a table with text or image data, and can be corrected by dropping and re-creating those rows.

Use the following steps to address the problem:

  1. Identify the table. Refer to “Finding an object name from a page number” in the chapter “Other Useful Tasks” in the most recent version of Troubleshooting and Disaster Recovery for instructions about how to use the dbcc page command to determine the table.

    WARNING! The procedure referenced in step 1 uses the dbcc page command. Use the dbcc page command only as directed. This command is undocumented, nonstandard, and is provided “as is” without any warranty. Sybase Technical Support does not support this command for general use. Although the command syntax is provided for reference, use this command only in the specific diagnostic situations described, and with the specific syntax shown. Failure to do so could cause performance problems and database corruption.

  2. Determine the first page of the text or image chain using dbcc pglinkage, using as the starting page the page number from the error message. For example, assuming that dbid=7 and the starting page number is 531:

    1> dbcc pglinkage(7, 531, 0, 1, 0, 0)
    2> go
    
    Object ID for pages in this chain = 208003772.
    Beginning of chain reached.
    Page : 531
    Page : 532
    Page : 530
    3 pages scanned. Object ID = 208003772.
    Last page in scan = 530.
    

    Page 530 is the first page of the text or image chain.

  3. Identify the rows with the bad data using the following command:

    1> select <column1> from <table_name> 
    2> where convert (int, textptr(<text_colname>)) 
    3> = <first_page_of_chain> 
    4> go
    

    Where <column1> is any column or columns in your table that will uniquely identify the rows.

  4. Drop the rows in question.

  5. Insert the rows back into the table.

  6. Run dbcc checktable on the table to verify that the problem has been corrected.

Versions in which this error is raised

All versions