ODBC database drivers and supporting files
This section lists files that are required for all ODBC database
connections from PowerBuilder or InfoMaker applications, as well
as files required for a specific database interface or DBMS.
PowerBuilder ODBC interface files
The following PowerBuilder ODBC interface files are required
if your application uses ODBC:
|
Name |
Description |
|---|---|
|
pbodb125.dll |
PowerBuilder ODBC interface |
|
pbodb125.ini |
PowerBuilder ODBC initialization file |
Installed path
Program FilesSybaseSharedPowerBuilder
Deployment path
Same directory as the application, in a directory on the system
path, or in the App Path registry key.
Registry entries
Notes
The PBODB125.INI file must be in a directory
defined by the HKEY_CURRENT_USERSoftwareSybasePowerBuilder12.5InitPath registry
setting or, in the absence of that key, in the same directory as
the DLL file. In most cases, the target deployment machine will
not have the registry setting and, therefore, the INI file should
be in the same directory as the DLL.
Microsoft ODBC files
Table 36-8 lists
the Microsoft ODBC files that are required if your application uses
ODBC.
|
Name |
Description |
|---|---|
|
DS16GT.dll |
Microsoft ODBC driver manager, DLLs, |
Installed path
Windows system directory.
Deployment path
Windows system directory.
Registry entries
None.
Notes
The Microsoft ODBC Driver Manager (ODBC32.dll)
and supporting files are usually already installed in the user’s
Windows system directory.
SQL Anywhere files
If your PowerBuilder application uses a SQL Anywhere database,
you need to deploy the SQL Anywhere DBMS as well as SQL Anywhere’s
ODBC database drivers.
Restrictions
PowerBuilder includes SQL Anywhere for use during the development process.
However, this product cannot be deployed royalty-free to your users.
If your application requires the data definition language
(DDL), a transaction log, stored procedures, or triggers, see your
Sybase sales representative.
If your application uses a standalone database, you can deploy
the SQL Anywhere Desktop Runtime System to users’ computers
without incurring additional license fees. The runtime system allows
the user to retrieve and modify data in the database, but does not
allow modifications to the database schema. It does not support
transaction logs, stored procedures, or triggers.
A full installation for the SQL Anywhere driver, runtime engine,
and supporting files is available in the PowerBuilder setup program.
Table 36-9 lists
some of the files that are installed. For more information see the RuntimeEdition.html file
in the installed SQL Anywhere directory. It contains a list of all
the SQL Anywhere files that can be freely deployed with PowerBuilder
applications to end users’ computers.
|
Name |
Description |
|---|---|
|
dbodbc11.dll |
SQL Anywhere ODBC driver |
|
dbbackup.exe |
SQL Anywhere backup utility |
|
dbcon11.dll |
Connection dialog box, required if you |
|
dbisqlc.exe |
Interactive SQL utility |
|
dblgen11.dll |
Language-specific string library (EN indicates |
|
dblib11.dll |
Interface library |
|
dbtool11.dll |
SQL Anywhere database tools |
|
dbunlspt.exe |
SQL Anywhere unload utility |
|
dbvalid.exe |
SQL Anywhere validation utility |
|
rteng11.exe |
Restricted runtime engine |
|
rteng11.lic |
License file for restricted runtime engine |
|
dbctrs11.dll |
Performance utility |
|
dbserv11.dll |
Server utility |
Installed path
Program FilesSybaseSQL
Anywhere 12in32 or in64
Deployment path
Same directory as the application, in a directory on the system
path, or in the App Path registry key.
Registry entries
See “App Path registry key” and “Configuring ODBC data
sources and drivers”.
Privilege requirements on Vista
When running under User Account Control, the SQL Anywhere
restricted runtime engine (rteng11.exe) and
other SQL Anywhere executables require elevated privileges. For
Windows Vista and later versions of Windows, you can use the SQL
Anywhere elevated operations agent (dbelevate11.exe)
to elevate the privileges of users running these executables and
allow non-elevated client processes to autostart elevated servers
or database engines. The following DLLs also require elevated privileges
when they are registered and unregistered: dbcon11.dll, dbctrs11.dll, dbodbc11.dll, dboledb11.dll,
and dboledba11.dll.
Notes
Supporting files should be installed in the same directory
as dbodbc11.dll. If you are not using the English
string library, make sure you deploy the appropriate version of
the language-specific string library.
Configuring ODBC data
sources and drivers
ODBC.INI
To allow the user to connect to a particular data source,
your installation program must provide a definition for that data
source in the ODBC.INI key in the registry on the computer that
accesses the data source, in HKEY_CURRENT_USER for
a user DSN or in HKEY_LOCAL_MACHINE for a
system DSN. The data source definition specifies the name and location
of the database driver as well as the command required to start
the database engine. The data source in the ODBC Data Sources key
must also be listed in ODBC.INI.
The following shows typical registry entries for a data source
called MyApp DB that uses SQL Anywhere. Registry keys are enclosed
in square brackets and are followed by string values for that key
in the format "Name"="Value":
|
1 |
[HKEY_CURRENT_USERSOFTWAREODBCODBC.INIMyApp DB]<br>"Driver"="C:Program FilesSybaseSQL Anywhere 12<br>   bin32dbodbc11.dll"<br>"Start"="c:program filessybaseSQL Anywhere 12in32<br>   rteng11.exe -c9m"<br>"UID"="dba"<br>"PWD"="sql"<br>"Description"="Database for my application"<br>"DatabaseFile"="C:Program Filesmyappsmyapp.db"<br>"AutoStop"="Yes"<br> <br><br>[HKEY_CURRENT_USERSOFTWAREODBCODBC.INI<br>   ODBC Data Sources]<br>"MyApp DB"="SQL Anywhere 12.0" |
ODBCINST.INI
Your installation program needs to make two types of entry
in the ODBCINST.INI key in HKEY_LOCAL_MACHINESOFTWAREODBC for
each driver that your deployed application uses:
-
Add
a string value with the name of the driver and the data value “Installed” to
the ODBC DRIVERS key in ODBCINST.INI -
Add a new key for each driver to the ODBCINST.INI key
with string values for Driver and SetupSome drivers require additional string values in ODBCINST.INI.
If the ODBC database driver files are not located in a directory
on the system path, you also need to add their location to the App
Paths key for the executable file.
If you are using ODBC drivers obtained from a vendor, you
can use the driver’s setup program to install the driver
and create registry entries.
The following shows a typical registry entry for SQL Anywhere.
A registry key is enclosed in square brackets and is followed by
string values for the key in the format "Name"="Value":
|
1 |
[HKEY_LOCAL_MACHINESOFTWAREODBCODBCINST.INI<br>   SQL Anywhere 12.0]<br>"Driver"="c:program filessybaseSQL Anywhere 12<br>   bin32dbodbc11.dll"<br>"Setup"="c:program filessybaseSQL Anywhere 12<br>   bin32dbodbc11.dll" |
For more information about the contents of
the registry entries for ODBC drivers and data sources, see Connecting
to Your Database.