Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Info

Support for ODBC was added in Profound.js 5.3.0.

...

An IBM account is required to access the downloads. Click on Downloads for IBM i Access Client Solutions, accept the license agreement, and use the ACS App Pkg link for the appropriate source operating system. For IBM i, use ACS PASE App Pkg. Installation instructions are included in each download package.

The IBM i version of the Application package installs via the open-source package manager "yum". See here for instructions on setting up yum on IBM i:

https://www.ibm.com/support/pages/node/706903

For Application Package installers for 32-bit Windows or languages other than English, visit the IBM ESS Website

...

OptionRequired Value
nam1
unicodesql1
tsft1

...

1

...

Creating a Credentials File

...

Code Block
[ODBC]
Driver=IBM i Access ODBC Driver
System=myIBMi
Naming=1
CommitMode=0
UnicodeSQL=1
TimestampFormat=1

Make the following adjustments to the file:

Change the value of the 'System' property to the target IBM i system's host name or IP address.

...

Code Block
SSL=1

Additional connection options can be added as desired.

...

To remove or change a DSN, simply edit or delete the file.

Optimizing ODBC Pool Performance

When the odbc package has to create several pool connections at once (such as when establishing the initial set of pool connections), queries can get held up until all the connections are completed. Establishing each connection can take some time, especially when connecting to IBM i over a WAN. This can result in a long delay running a query while connections are being established. To mitigate this, Profound.js begins the process of establishing the connection pool immediately as the server is starting up. However, delays can occur if the connection pool is configured such that it can grow by large increments. See the pool configuration options here:

https://www.npmjs.com/package/odbc#constructor-odbcpoolconnectionstring

It's recommended to use a configuration like this to prevent the pool from growing once the initial connections are established:

Code Block
"driverOptions": {
  "connectionString": "DSN=myIBMi;",
  "initialSize": 10,
  "maxSize": 10,
  "shrink": false
}

If you need to configure the pool so that it can grow, make sure that it grows by only 1 or 2 connections at a time. For example:

Code Block
"driverOptions": {
  "connectionString": "DSN=myIBMi;",
  "initialSize": 10,
  "maxSize": 20,
  "incrementSize": 2
  "shrink": false
}