DefaultProcOwner

Description

The DefaultProcOwner parameter lets you set a default owner for a stored procedure. The parameter takes effect only when the stored procedure is not qualified. For ODBC, the PBNewSPInvocation parameter must also be set.

Applies to

Syntax

DefaultProcOwner='value'

Parameter

Description

value

A string specifying the name of the default owner of the stored procedure

Usage

The parameter can be set dynamically at runtime after connecting to a database. You can also set it in your PBODB125.INI file if you want to create and retrieve data into a DataWindow with a stored procedure data source in the DataWindow painter. The runtime setting overrides the setting in PBODB125.INI.

You can also cancel the setting at runtime. If you do so, PowerBuilder uses the current user as the owner of a non-qualified stored procedure when it obtains the parameters of the stored procedure.

Examples

Example 1

To set the default owner to proms in PBODB125.INI:

[SQL Anywhere]                                DefaultProcOwner='proms'                                 

In code:

SQLCA.DBParm="DefaultProcOwner='proms'";  

To cancel the setting:

 SQLCA.DBParm="DefaultProcOwner=''";

Note that the single quotes in the previous example contain an empty string, not a space.

See also

PBNewSPInvocation