Help - Database Connection Settings
 

PowerWeb Database Connections allow you to attach a name to a specific database login connection and use that symbolic name within your WebMacro code.

Using Database Connections improves security because server names, user names and passwords are not stored in any user-visible file.

Database Connections also considerably improve performance (for quick queries this can be as much as 10 times faster) and allow management of the number of connections to a server, to perform load balancing and to comply with database license agreements regarding the number of simultaneous users.

Do not set your combined number of Permanent, Cached and AdHoc connections to be greater than the number of simultaneous connections allowed by your database manager, otherwise your database manager will refuse connections and an error message will be returned to your users.

Database Reference Manual

Config:/Query/Database/Connect/*/
SettingExplanationDefault /
Example
Data
Type
Access
R,W,A,D
Vendor The name of the database vendor or software running the database server. You can define new database interfaces. Sybase PointerR,W
Server The name of the database server on the network. Not applicable for ODBC, IBM DB/2 and SQL Anywhere.

Sybase and MicroSoft SQL Server implement a multi-tiered data source (the first level is a server name and the second is a database name), so you simply specify the server name here and the database name in "DataSource".

sybase TextR,W
DataSource The name of the data source (for ODBC, IBM DB2 and SQL Anywhere) or database (Sybase or MicroSoft SQL Server) to connect to. For ODBC, the full data source name (which can be obtained from the Windows Control Panel ODBC Administrator) is required. SQL Anywhere 5.0 Sample TextR,W
UserID The name of the user to login to the data source with.
If this text is "PowerWeb", then the user name sent by the client's browser for HTTP or FTP authentication is used.

Note that if you use "PowerWeb", you may only specify ad-hoc connections, no permanent or cached connections are possible.

sa TextR,W
Password The password to use when logging in.
If this text is "PowerWeb", then the password sent by the client's browser for HTTP or FTP authentication is used.

Note that if you use "PowerWeb", you may only specify ad-hoc connections, no permanent or cached connections are possible.

secret TextR,W
MaxPermanent The maximum number of permanently open connections to maintain to the specified database. Permanent connections are the fastest because there is no overhead of login/logoff for each query. Connections are established on a demand basis, so only the number of connections actually in use simultaneously get established, not the maximum. 0 IntegerR,W
MaxCache The maximum number of cached connections to maintain to the specified database. Cached connections are the second fastest because if multiple queries are sent within the timeout period, there is no overhead of login/logoff for each query. Connections are established on a demand basis and are released when the connection has not been used for a specified timeout period.

Cached connections are particularly useful when PowerWeb is not the only client of your database server and you need to balance the load between Web serving and traditional client/server applications.

10 IntegerR,W
MaxAdHoc The maximum number of ad-hoc connections to allow to the specified database. Ad-hoc connections are the slowest because of the overhead of login/logoff for each query. Connections are established on a demand basis and are released immediately the query is completed. 0 IntegerR,W
CacheTimeout The time in milliseconds after which cached connections to the database will be released if not used within that time period. The actual time before the connection is released may be up to 15 seconds longer than the specified time. 60000 IntegerR,W