syntaxsql 複製 CREATE [ OR ALTER ] FUNCTION [ schema_name. ] function_name ( [ { @parameter_name [ AS ] [ type_schema_name. ] parameter_data_type [ NULL ] [ = default ] [ READONLY ] } [ , ...n ] ] ) RETURNS return_data_type [ WITH <function_option> [ , ...n ] ]...
FunctionOption FunctionOptionKind FunctionReturnType FunctionStatementBody GeneralSetCommand GeneralSetCommandType GeneratedAlwaysType GenericConfigurationOption GetConversationGroupStatement GlobalFunctionTableReference GlobalVariableExpression GoToStatement GrandTotalGroupingSpecification GrantStatement GrantSt...
return_data_type 這是純量使用者定義函數的傳回值。就 Transact-SQL 函數而言,除了 timestamp 資料類型以外,其他所有資料類型 (包括 CLR 使用者定義型別) 都是允許的資料類型。就 CLR 函數而言,除了 text、ntext、image 及 timestamp 資料類型以外,其他所有資料類型 (包括 CLR 使用者定義型別) 都是允許的資料...
The CREATE FUNCTION (SQL table) statement creates an SQL table function at the current server. The function returns a set of rows.
This CREATE FUNCTION (SQL scalar) statement creates an SQL function at the current server. The function returns a single result. Invocation This statement can be embedded in an application program or issued interactively. It is an executable statement that can be dynamically prepared. Authorization ...
適用於:SQL Server 2014 (12.x) 和更新版本,以及 Azure SQL Database。確定程序所參考的資料表無法卸除或改變。 原生編譯預存程序需要 SCHEMABINDING。 (如需詳細資訊,請參閱原生編譯的預存程序。)SCHEMABINDING 限制和使用者定義函式的相關限制相同。 如需詳細資訊,請參閱 CREATE FUNCTION (Transact-SQL) 中的...
适用于:SQL Server 2014 (12.x) 及更高版本和 Azure SQL 数据库。确保过程引用的表不能删除或修改。 SCHEMABINDING 在本机编译存储过程中是必需的。 (有关详细信息,请参阅本机编译的存储过程。)SCHEMABINDING 限制与其对用户定义的函数的限制是相同的。 有关详细信息,请参阅 CREATE FUNCTION (Transact-SQL) 中...
--Transact-SQL Scalar Function Syntax CREATE FUNCTION [ schema_name. ] function_name ( [ { @parameter_name [ AS ][ type_schema_name. ] parameter_data_type [ = default ] [ READONLY ] } [ ,...n ] ] ) RETURNS return_data_type [ WITH <function_option> [ ,...n ] ] [ AS ]...
syntaxsql Copy CREATE [ OR ALTER ] FUNCTION [ schema_name. ] function_name ( { @parameter_name [ AS ] [ type_schema_name. ] parameter_data_type [ NULL ] [ = default ] } [ , ...n ] ) RETURNS { return_data_type } [ WITH <clr_function_option> [ , ...n ] ] [ AS ]...
routine so that it can be called from SQL and PL/SQL. The call specification tells Oracle Database which Java method, or which named function in which shared library, to invoke when a call is made. It also tells the database what type conversions to make for the arguments and return ...