SQL Yoga version 1.1.0 build 4 :: Visit website

Printer friendly version

command dbconn_createObject

Creates a Database Connection for a Database.

command dbconn_createObject pName, pAdaptor, pType
Parameters
TypeNameDescription
Simple parameter. pName The Database Connection name. You will use this name whenever you refer to the connection in the API.
Simple parameter. pAdaptor The adaptor to use to connect to the database that the connection is associated with: mysql, odbc, postgresql, sqlite, valentina.
Simple parameter. pType The type of database you are connecting to. Only required for ODBC.
OptionalSimple parameter. [pDBKey] Database Object to associate connection with. Default is name returned by sqlyoga_getDefaultDatabase().
Description

SQL Yoga allows you to have multiple database connections. You can define one database connection for your development environment and another for distribution. Changing which connection SQL Yoga uses for a Database Object is as simple as:

dbobject_setprop "default connection", "development"

Return

Error message