If a database has any objects (stored procedures, triggers, and so on) that perform a select * on a table from which you have dropped a column, an error message lists the missing column. This occurs even if you create the objects using the with recompile option. For example, if you dropped the postalcode column from the authors table, any stored procedure that performed a select * on this table issues this error message:
Msg 207, Level 16, State 4: Procedure ‘columns’, Line 2: Invalid column name ‘postalcode’. (return status = -6)
This message does not appear if you add a new column and then run an object containing a select *; in this case, the new column does not appear in the output.
You must drop and re-create any objects that reference a dropped column.
Copyright © 2005. Sybase Inc. All rights reserved. |