Name: revSetDatabaseDriverPath

Type: command

Syntax: revSetDatabaseDriverPath <driverFolder>

Summary:
Specifies where the <Database library> should look for 
<database driver|database drivers>.

Associations: database library

Introduced: 2.0

OS: mac, windows, linux, ios, android

Platforms: desktop, server, mobile

Security: disk, network

Example:
revSetDatabaseDriverPath "../drivers/"

Example:
revSetDatabaseDriverPath the defaultFolder

Parameters:
driverFolder:
The name and location of the folder where the database driver files are
stored. 

Description:
Use the <revSetDatabaseDriverPath> <command> if you want to place the
database drivers your application uses somewhere other than the same
folder as the application.

To use an external SQL database, the Database library needs to
communicate via a database driver for the database you're using. By
default, the Database library looks for drivers in the same folder as
the application. If you try to work with the Database library, and the
database driver is not where LiveCode expects it to be, a script error
will result.

If the database drivers your application needs are installed in a
different folder, use the <revSetDatabaseDriverPath> <command> before
you use any other <command|commands> or <function|functions> in the
<Database library>, and before you display a <field(keyword)> that
you've set up to show data from a <database> (using the Database pane in
the <field(object)|field's> <property inspector>). Usually, the best
place for this <command> is in your <stack|stack's> <startup> or
<preOpenStack> <handler>.

>*Important:*  The <revSetDatabaseDriverPath> <command> is part of the 
> <Database library>. To ensure that the <command> works in a 
> <standalone application>, you must include this 
> <LiveCode custom library|custom library> when you create your 
> <standalone application|standalone>. In the Inclusions pane of the 
> <Standalone Application Settings> window, make sure both the 
> "Database" library checkbox and those of the database drivers you are 
> using are checked.

References: specialFolderPath (function), revOpenDatabase (function),
revGetDatabaseDriverPath (function), LiveCode custom library (glossary),
property inspector (glossary), handler (glossary), database (glossary),
Standalone Application Settings (glossary),
standalone application (glossary), database driver (glossary),
function (glossary), command (glossary), field (keyword),
Database library (library), startup (message), preOpenStack (message),
field (object), stack (object), defaultFolder (property)

Tags: database

