|
You must know the name of the server where the database is located. If the database already has a DBNAME, PCC uses it. If you wish to create a new database but use existing data files, you must know the location of the data files on the server.
To create up an Engine DSN on a remote machine, you must possess administrator rights on the remote machine that houses the database you wish to access. You must have OS system rights to create a System DSN on the local machine.
To Set Up Database Access on Windows
Existing databases with a DBNAME on the registered server can then be accessed from PCC.
The new database can then be accessed from PCC.
To Set Up ODBC Database Access on Windows
Existing databases with a DBNAME and a DSN on the registered server can then be accessed from PCC.

By default, PCC creates a system DSN with the same name as the database name. The new database has a DSN associated with it and can be accessed through ODBC.
To Set Up Database Access on a NetWare Server from a Client Workstation
Existing databases on the registered server can then be accessed from PCC.
The new database can then be accessed from PCC.
To Set Up ODBC Database Access on on a NetWare Server from a Client Workstation
Existing databases with DSNs on the registered server can then be accessed from PCC.

By default, PCC creates a system DSN with the same name as the database name. The new database has a DSN associated with it and can be accessed through ODBC.
To Set Up a Named Database and Engine DSN from a Linux Server
Database names are created in Linux by using the dbmaint utility at the server. For a complete description of dbmaint, see dbmaint or read the dbmaint man page.
Note
This utility can only be run by user accounts belonging to grouppvsw. See Getting Started With Pervasive PSQL (Server edition) for information on Pervasive PSQL Linux utilities and user accounts.
dbmaint a | d | l [-b] [-i] [-e] -nDbname [-ldictpath] [-ddatapath]The list of commands for dbmaint include:
a - add database name
d - delete database name
l - list all database namesOptions include:
-b - create Bound database
-i - create database with Relational Integrity enforced
-e - do not create dictionary files for database
-nDBName - specify database name
-lDictpath - specify dictionary path
-dDatapath - specify data path
-a - show full data in the DBNames listFor example, to create DBName TEST with relational integrity, type:
dbmaint a -i -nTEST
Note
Unless datapath is specified, the new database is created in the default location, $PVSW_ROOT/data. Likewise, if dictpath is not specified, the dictionary is created in the default location.
${PVSW_ROOT}/etc/odbc.ini. SQLMGR required settings:
${PVSW_ROOT}/etc/odbc.ini
Note
The value of${PVSW_ROOT}is typically/usr/local/psql.
Server data source - the one to which remote calls will be redirected:
[DSN name] Driver=/usr/local/psql/lib/libodbcci.so Description=Test Pervasive database DBQ=DBNameIn addition, each data source should be mentioned in the section
[[ODBC Data Sources]as in the following example:ODBC Data Sources] dsnName1=Pervasive PSQL database dsnName2=Pervasive PSQL databaseFor example, if you have in
odbc.ini:[MyDSN] Driver=/usr/local/psql/lib/libodbccci.so Description=test DBQ=MyDBthen your
[ODBC Data Sources] MyDSN=Pervasive PSQL databaseodbc.inishould have:
Note
Because Linux is case sensitive, the[DSN name]must be input exactly as listed under[ODBC Data Sources].
dsnadd utility by typing the following at the command line:
To make a client able to access a remote Pervasive PSQL database
Existing databases on the remote server can then be accessed from PCC.
The new database can then be accessed from PCC.
To set up a Client DSN using ODBC Administrator
Note
Pervasive PSQL does not support File DSNs. You must use User or System DSNs. System DSNs are generally preferred, because they are available to all users on a given computer.
The following dialog box appears:


Do not modify the Network settings or TCP/IP Port Number unless you have first reviewed the information in ODBC DSN Creation Options in Advanced Operations Guide.

If no databases appear in the drop-down list, either you selected the wrong server, or you need to have your system administrator name the server databases and create Engine DSNs for each of them before you can access them.
Setting Up a Client DSN on a Linux Workstation
While it is possible to access a database from a Linux server by a Linux client, there are no Pervasive PSQL utilities (except dsnadd) that can be used on the client. A Linux client configuration would be used for independent applications, such as web applications.
To add a client data source, execute the following command:
dsnadd -dsn=myDSN-desc=datasource-host=psqlhost-sdsn=svDSNmyDSN is a name you want to assign to the new Client DSN.
datasource is any string to describe the data source.
psqlhost is the name of the network host where your Pervasive PSQL database resides.
svDSN is the name of the Engine DSN on the Pervasive PSQL host.
Note
The datasource on the server must be named first.
For example, to create a Client DSN named TEST on host NewDev, where the Engine DSN name for the database is NewTest, type
For more information about the dsnadd utility, please see Getting Started With Pervasive PSQL (Server edition).
|
Chapter contents
Prev topic: Setting Up ODBC Database Access
|