Overview: Some software is developed using PowerBuild, the background database engine is used by the Sybase SQL Anywhere 5.5 version. The default installation can only be used in a single machine. Through the methods described herein, the client's client software (DJPC.exe) and the background database engine runs on different computers, respectively, and passes the data over the network. Such a database engine can serve multiple computers.
Key: Appropriate ODBC settings and work with some command lines to start the database engine and client separately.
Necessary: Whether running the database engine computer, running the software client or other computer that requires a database engine, you must install Sybase SQL Anywhere 5.5.
(Note: The database engine can be on the same computer with the software or other application to use the engine)
I need to use the Sybase Sqlanywhere component (program):
1.dbsrv50.exe This is the database engine of Sybase SQL Anywhere;
2.Dbclient.exe This is the client program for Sybase SQL Anywhere to connect to the database engine;
These programs are located under the SQL Anywhere / Win32 folder of the Sybase installation folder.
The operating system components that need to be used:
ODBC Administrator (under the control panel management tool folder)
Important: In the settings of Sybase SQL Anywhere, including data source names, database names, etc. are sensitive. If you encounter the correct but unable to connect, please pay attention to the cases of the following names.
First, set and run the database engine
On the computer that needs to run the database engine, open the ODBC Administrator, and convert it to the system DSN.
Select Add, Driver Type Select "Sybase Sql Anywhere"
After clicking "Finish", the configuration window for Sybase SQL Anywhere ODBC is automatically appeared:
Data source name is set to DJPC, username and passwords are DBA and SQL, specify the server name and database name to DJPC, then select Database File, Finally, click Option:
Note that "Start Command" is modified from "dbeng50.exe" to "dbsrv50.exe" (the former is a stand-alone database engine, the latter is the network database engine we want), then write "-x Netbios" in the parameter. Means that specifying the database engine only uses the NetBIOS command to declare server. After testing, TCPIP cannot be used, always said that the server name already exists, I don't know what to, and finally click OK, the ODBC configuration section is completed.
In theory, after this database engine is configured, when there is a database request, the engine should be able to start automatically, but most cases need to be manually started in advance: running under CMD:
Where parameters -C
40M
"The specified engine uses 40 trillion memory as the buffer (adjustable as needed, the bigger the buffer is, the better performance. If this parameter is not specified, the default buffer is only 2 megabytes, very low performance).
The following is the screen after the database engine startup:
Second, set the client connection
The client's ODBC setting is still completed in the ODBC Administrator, steps and settings the database engine, just the configuration of the configuration and the components of the Sybase SQL Anywhere used: (note case)
Look at the options:
Set the settings.
When the client has a request for the ODBC, the system automatically runs DBClient to connect the database engine.
ilittlefat
November 23, 2004