Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 17 » MobiLink - Server Administration » MobiLink reference » MobiLink server system procedures

ml_add_connection_script system procedure

Add or delete SQL connection scripts in the consolidated database.

Syntax
ml_add_connection_script ( 
'version', 
'event', 
'script'  
)
Parameters
Syntax Description
version

VARCHAR(128). The version name.

event

VARCHAR(128). The event name.

script

TEXT. The script contents. For Adaptive Server Enterprise, this parameter is VARCHAR(16384). For IBM DB2 LUW, this parameter is VARCHAR(4000). For Oracle, this parameter is CLOB.

Remarks

To delete a connection script, set the script contents parameter to null.

When you add a script, the script is inserted into the ml_script table and the appropriate references are defined to associate the script with the event and script version that you specify. If the version name is new, it is automatically inserted into the ml_version table.

Example

The following statement adds a connection script associated with the begin_synchronization event to the script version custdb in a SQL Anywhere consolidated database. The script itself is the single statement that sets the @EmployeeID variable.

call ml_add_connection_script( 'custdb',
 'begin_synchronization',
 'set @EmployeeID = {ml s.username}' )