Synopsis
Returns the value of a WhereScape RED metadata Parameter  [SQL Server only] .
Description
Returns the value of the specified parameter from the DSS_PARAMETER metadata table. This routine is a FUNCTION that is only available for SQL Server. For SQL Server, Teradata, and DB2 there is a WsParameterRead PROCEDURE that returns both the parameter value and comment. For Oracle the WsParameterRead FUNCTION is equivalent to the SQL Server WsParameterReadF FUNCTION.
Typically, this routine is used by procedures to read information that is written by another process (automatically or manually via the RED  Tools > Parameters  menu item), which is external to the procedure.
Input

Input

Description

Parameter Name

The name of the WhereScape RED metadata parameter to be retrieved. The case-sensitive name must exactly match an existing parameter, otherwise a NULL value is returned.

Output

Output

Description

Parameter Value

The value of the parameter. Corresponds to the Value property that is visible and maintainable via Tools > Parameters.

SQL Server

SQL Server Parameters: WsParameterReadF
Callable Routine Type: FUNCTION.

Parameter Name

Datatype

Mode

@p_parameter

VARCHAR(64)

IN

FUNCTION Return Value

VARCHAR(4000)

OUT-Function

Note

There is also a corresponding WsParameterRead PROCEDURE available for SQL Server.

SQL Server Examples: WsParameterReadF

DECLARE @v_current_date varchar(4000)
SELECT @v_current_date = dbo.WsParameterReadF('CURRENT_DATE')


  • No labels