Topics   All   Mac OS X (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server (Not)   Client   Old   Guides   Examples
New in version: 6.2   6.3   6.4   6.5   7.0   7.1   7.2   7.3   7.4   7.5    Statistic  

SQL.SetClient

Assigns an DBMS client for the connection.

Component Version macOS Windows Server FileMaker Cloud FileMaker iOS SDK
SQL 2.6 Yes Yes Yes Yes Yes

MBS( "SQL.SetClient"; Connection; Client )

Parameters

Parameter Description Example value
Connection The connection reference number gained with SQL.NewConnection. $Connection
Client The name of the database client to use. "SQLite"

Result

Returns "OK" on success.

Description

Assigns an DBMS client for the connection.

You can set a client in Connect method, in this case you don't need to use setClient method. The main destination of this method is to connect to a server with no connection to a database (for example, to check a client availability and version). But if you are calling Connect method with no specified client you have to use setClient method before.

If you are calling setClient method when the connection is set to another client the previous connection will be disconnected and new client will be set.

Pass one of this values: ODBC, Oracle, SQLServer, Firebird, InterBase, SQLBase, DB2, Informix, Sybase, MySQL, PostgreSQL or SQLite.
Be aware that for most database servers, you need to specify client library with SQL.SetConnectionOption.

Examples

Sets client to be SQLite:

MBS( "SQL.SetClient"; $Connection; "SQLite" )

See also

Example Databases


SQL.SetAutoCommit   -   SQL.SetCommandOption

Feedback: Report problem or ask question.




Links
MBS Xojo Chart Plugins