1 Version 4.0 -- 1/15/89 sp_help
______________________________________________________________________
NAME: sp_help
FUNCTION:
Reports information about a database object (any object listed in
sysobjects) or about a SQL Server-supplied or user-defined data-
type.
SYNTAX:
sp_help [objname]
EXAMPLES:
1) sp_help
sp_help Version 4.0 -- 1/15/89 2
______________________________________________________________________
Displays a brief listing of each object in sysobjects, giving
its name, owner, and object type; and of each user-defined
datatype in systypes, giving its name, storage type, length,
nulltype, default name, and rule name. Nulltype is 0 if null
values are not permitted, 1 if null values are allowed.
2) sp_help publishers
Displays information about the publishers table:
Name Owner Type
------------------------------ ------------------------------ ----------------
publishers dbo user table
Data_located_on_segment When_created
------------------------------ --------------------
3 Version 4.0 -- 1/15/89 sp_help
______________________________________________________________________
default Nov 17 1988 7:36PM
Column_name Type Length Nulls Default_name Rule_name
--------------- --------------- ------ ----- --------------- ---------------
pub_id char 4 0 NULL pub_idrule
pub_name varchar 40 1 NULL NULL
city varchar 20 1 NULL NULL
state char 2 1 NULL NULL
index_name index_description index_keys
-------------------- ------------------------------------ -------
pubind clustered, unique located on default pub_id
No defined keys for this object.
(1 row affected, return status = 0)
sp_help Version 4.0 -- 1/15/89 4
______________________________________________________________________
PARAMETERS:
objname - is the name of any object in sysobjects or any user-
defined datatype in systypes. Database names are not accept-
able.
COMMENTS:
o The procedure looks for an object in the current database only.
o System procedures do not work on temporary tables because a
procedure cannot access a temporary object unless it created
the object itself during the current session.
MESSAGES:
The procedure gives information about objects in the current
database only. You have included the database name in the
objname parameter.
5 Version 4.0 -- 1/15/89 sp_help
______________________________________________________________________
The specified object does not exist in the current database.
The table or view has no defined keys.
TABLES USED:
syscolumns, sysobjects, systypes, master.dbo.spt_values
PERMISSIONS:
Execute permission to public.
SEE ALSO:
sp_helpalias, sp_helpgroup, sp_helpindex, sp_helprotect,
sp_helpuser