sys.numbered_procedure_parameters (Transact-SQL)sys.numbered_procedure_parameters (Transact-SQL)

适用对象: yesSQL ServeryesAzure SQL 数据库noAzure SQL 数据仓库no并行数据仓库APPLIES TO: yesSQL Server noAzure SQL Database noAzure SQL Data Warehouse noParallel Data Warehouse

带编号过程的每个参数都在表中对应一行。Contains one row for each parameter of a numbered procedure. 当您创建带编号的存储过程时,基过程的编号为 1。When you create a numbered stored procedure, the base procedure is number 1. 所有后续过程的编号依次为 2、3 等。All subsequent procedures have numbers 2, 3, and so forth. sys.numbered_procedure_parameters包含所有后续过程,编号为 2 的参数定义及更高版本。sys.numbered_procedure_parameters contains the parameter definitions for all subsequent procedures, numbered 2 and greater. 该视图不显示基存储过程(编号 = 1)的参数。This view does not show parameters for the base stored procedure (number = 1). 基存储过程类似于无编号的存储过程。The base stored procedure is similar to a nonnumbered stored procedure. 因此,在表示其参数sys.parameters (TRANSACT-SQL)Therefore, its parameters are represented in sys.parameters (Transact-SQL).


不推荐使用带编号的过程。Numbered procedures are deprecated. 建议您不要使用带编号过程。Use of numbered procedures is discouraged. 当编译使用此目录视图的查询时,将会激发 DEPRECATION_ANNOUNCEMENT 事件。A DEPRECATION_ANNOUNCEMENT event is fired when a query that uses this catalog view is compiled.


带编号的过程不支持 XML 和 CLR 参数。XML and CLR parameters are not supported for numbered procedures.

列名Column name 数据类型Data type 描述Description
object_idobject_id intint 此参数所属的对象的 ID。ID of the object to which this parameter belongs.
procedure_numberprocedure_number smallintsmallint 对象中这种过程的数目(2 或更多)。Number of this procedure within the object, 2 or greater.
namename sysnamesysname 参数的名称。Name of the parameter. 在中是唯一procedure_numberIs unique within procedure_number.
parameter_idparameter_id intint 参数的 ID。ID of the parameter. 在中是唯一procedure_numberIs unique within the procedure_number.
system_type_idsystem_type_id tinyinttinyint 参数的系统类型的 ID。ID of the system type of the parameter
user_type_iduser_type_id intint 为用户的参数定义的类型的 ID。ID of the type, as defined by user, of the parameter.
max_lengthmax_length smallintsmallint 参数的最大长度(字节)。Maximum length of the parameter in bytes.

-1 = 列数据类型为 varchar(max)、nvarchar(max) 或 varbinary(max)。-1 = Column data type is varchar(max), nvarchar(max), or varbinary(max).
精度precision tinyinttinyint 如果参数是基于数值的,则表示参数的精度;否则为 0。Precision of the parameter if numeric-based; otherwise, 0.
scalescale tinyinttinyint 如果参数是基于数值的,则表示参数的小数位数;否则为 0。Scale of the parameter if numeric-based; otherwise, 0.
is_outputis_output bitbit 1 = 输出或返回参数;否则为 01 = Parameter is output or return; otherwise, 0
is_cursor_refis_cursor_ref bitbit 1 = 参数为游标引用参数。1 = Parameter is a cursor-reference parameter.


带编号的过程不支持 XML 和 CLR 参数。XML and CLR parameters are not supported for numbered procedures.


目录视图中仅显示用户拥有的安全对象的元数据,或用户对其拥有某些权限的安全对象的元数据。The visibility of the metadata in catalog views is limited to securables that a user either owns or on which the user has been granted some permission. 有关详细信息,请参阅 Metadata Visibility ConfigurationFor more information, see Metadata Visibility Configuration.

请参阅See Also

对象目录视图 (Transact-SQL) Object Catalog Views (Transact-SQL)
目录视图 (Transact-SQL)Catalog Views (Transact-SQL)