Any suggestions? Export (0) Print
Expand All
Collapse the table of content
Expand the table of content
Expand Minimize


SQL Server 2000

  Topic last updated -- June 2007

Contains entries for each view, rule, default, trigger, CHECK constraint, DEFAULT constraint, and stored procedure. The text column contains the original SQL definition statements, which are limited to a maximum size of 4 MB. This table is stored in each database.

Important  None of the entries in syscomments should be deleted. If an entry in syscomments is manually removed or modified, the corresponding stored procedure will not function properly. To obfuscate stored procedure definitions, use CREATE PROCEDURE with the ENCRYPTION keyword.

Column name Data type Description
id int Object ID to which this text applies.
number smallint Number within procedure grouping, if grouped.  0 for entries that are not procedures.
colid smallint Row sequence number for object definitions longer than 4,000 characters.
status smallint For internal use only.
ctext varbinary(8000) Actual text of the SQL definition statement.
texttype smallint 0 = User-supplied comment.
1 = System-supplied comment.
4 = Encrypted comment.
language smallint For internal use only.
encrypted bit Indicates whether the procedure is obfuscated.

0 = Not obfuscated.
1 = Obfuscated.

compressed bit Indicates whether or not the procedure is compressed.

0 = Not compressed
1 = Compressed

text nvarchar(4000) Actual text of the SQL definition statement.

© 2015 Microsoft