Connecting from a procedure with the CONNECT statement
The CONNECT statement allows you to connect to a database from an ABL procedure or from the Procedure Editor.
The following CONNECT statements connect the appldb1 database in single-user mode, the appldb2 database in multi-user mode, and the databases specified in the parameter file, parm3.pf (respectively):
Connecting with the CONNECT statement is very similar to connecting at startup. Although it is possible to connect to several databases within one CONNECT statement, it is a good idea to connect only one database per CONNECT statement. A connection failure for one database causes a termination of the current CONNECT statement, leaving any subsequent database specified with the CONNECT statement unconnected. For detailed information about the CONNECT statement, see OpenEdge Development: Programming Interfacesq and OpenEdge Development: Programming Interfaces.