FIX: Error 21761 When Binding Non-DBO Default

ID: Q202429


The information in this article applies to:
  • Microsoft SQL Server version 7.0

BUG #: 53106 (SQLBUG_70)

SYMPTOMS

When a user of a database other than the database owner (DBO) creates a default using SQL Server Enterprise Manager and the DBO then tries to bind the default to a column of a table in that database using Enterprise Manager, the following error occurs:

Error 21761: [SQL-DMO]Default Default name not found.


CAUSE

The SQL Server Enterprise Manager calls the sp_bindefault stored procedure with the parameters default name and column name. While passing the default name, Enterprise Manager does not qualify the default name with name of the object owner.


WORKAROUND

To work around this problem, bind the default using the sp_bindefault stored procedure in SQL Server Query Analyzer. Make sure the default name is fully qualified, as in the following example:

database name.user name.default name
For example, to bind the default "my_default", created by the user "guest", to the qty column of the sales table in the pubs database, you would execute the following:

sp_bindefault 'pubs.guest.my_default', 'sales.qty' 


STATUS

Microsoft has confirmed this to be a problem in SQL Server version 7.0. This problem has been corrected in U.S. Service Pack 1 for Microsoft SQL Server version 7.0. For information about downloading and installing the latest SQL Server Service Pack, see http://support.microsoft.com/support/sql/.

For more information, contact your primary support provider.

Additional query words: ent man entman err message msg

Keywords : kbbug7.00
Version : winnt:7.0
Platform : winnt
Issue type : kbbug


Last Reviewed: November 17, 1999
© 2000 Microsoft Corporation. All rights reserved. Terms of Use.