27 jul 2011

Sysobjects

--'sysobjects' tiene objectos (tablas, Stores, Funcions, etc)
--'syscolumns' tiene objectos (tablas, Stores, Funcions, etc)

SELECT SO.NAME, SC.NAME

FROM sysobjects SO INNER JOIN syscolumns SC
ON SO.ID = SC.ID

WHERE SO.XTYPE = N'U'

ORDER BY SO.NAME, SC.NAME

Column nameData typeDescription
namesysnameObject name
idintObject identification number
xtypechar(2)Object type. Can be one of the following object types:
AF = Aggregate function (CLR)
C = CHECK constraint
D = Default or DEFAULT constraint
F = FOREIGN KEY constraint
L = Log
FN = Scalar function
FS = Assembly (CLR) scalar-function
FT = Assembly (CLR) table-valued function
IF = In-lined table-function
IT = Internal table
P = Stored procedure
PC = Assembly (CLR) stored-procedure
PK = PRIMARY KEY constraint (type is K)
RF = Replication filter stored procedure
S = System table
SN = Synonym
SQ = Service queue
TA = Assembly (CLR) DML trigger
TF = Table function
TR = SQL DML Trigger
TT = Table type
U = User table
UQ = UNIQUE constraint (type is K)
V = View
X = Extended stored procedure
uidsmallintSchema ID of the owner of the object.
For databases upgraded from an earlier version of SQL Server, the schema ID is equal to the user ID of the owner.
Important noteImportant
If you use any of the following SQL Server DDL statements, you must use the sys.objects catalog view instead of sys.sysobjects.CREATE | ALTER | DROP USERCREATE | ALTER | DROP ROLECREATE | ALTER | DROP APPLICATION ROLECREATE SCHEMA ALTER AUTHORIZATION ON OBJECT
Overflows or returns NULL if the number of users and roles exceeds 32,767.
For more information, see Querying the SQL Server System Catalog.
infosmallintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
statusintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
base_schema_verintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
replinfointIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
parent_objintObject identification number of the parent object. For example, the table ID if it is a trigger or constraint.
crdatedatetimeDate the object was created.
ftcatidsmallintIdentifier of the full-text catalog for all user tables registered for full-text indexing, and 0 for all user tables that are not registered.
schema_verintVersion number that is incremented every time the schema for a table changes. Always returns 0.
stats_schema_verintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
typechar(2)Object type. Can be one of the following values:
AF = Aggregate function (CLR)
C = CHECK constraint
D = Default or DEFAULT constraint
F = FOREIGN KEY constraint
FN = Scalar function
FS = Assembly (CLR) scalar-function
FT = Assembly (CLR) table-valued functionIF = In-lined table-function
IT - Internal table
K = PRIMARY KEY or UNIQUE constraint
L = Log
P = Stored procedure
PC = Assembly (CLR) stored-procedure
R = Rule
RF = Replication filter stored procedure
S = System table
SN = Synonym
SQ = Service queue
TA = Assembly (CLR) DML trigger
TF = Table function
TR = SQL DML Trigger
TT = Table type
U = User table
V = View
X = Extended stored procedure
userstatsmallintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
sysstatsmallintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
indexdelsmallintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
refdatedatetimeIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
versionintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
deltrigintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
instrigintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
updtrigintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
seltrigintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.
categoryintUsed for publication, constraints, and identity.
cachesmallintIdentified for informational purposes only. Not supported. Future compatibility is not guaranteed.

No hay comentarios:

SSIS - Package en blanco

Como solucionarlo: 1. Renombrar Package 2. Guardar package 3. Cerrar Solución.