In Windows environments, IBM Informix ODBC Driver provides a GUI to configure DSNs.
To configure a DSN:
For a description of values, see Table 5 and Table 6. Values are shown in the order that they appear in each section.
Required Values | Description |
---|---|
Data Source Name | DSN to access
This value is any name that you choose. Data Source Name is like an envelope that contains all relevant connection information about the DSN. |
Database Name | Name of the database to which the DSN connects by default |
Host Name | Computer on which Server resides |
Protocol | Protocol used to communicate with Server
Once you have added a DSN, the pull-down menu will display the available choices. |
Server Name | Informix database server on which Database resides |
Service | Informix database server process that runs on
your Host computer
Confirm the service name with your system administrator or database administrator. |
To configure a user DSN, go to step 3. To configure a system DSN, click the System DSN tab and go to step 3. All subsequent steps are the same to configure either a user DSN or a system DSN.
The Create New Data Source dialog box appears.
The General page for the IBM Informix ODBC Driver Setup dialog box appears.
For a description of the values, see Table 5 and Table 6.
To save the values you chose and verify that your DSN connects successfully, click Apply & Test Connection. An ODBC Message dialog box appears. The box tells you if your connection was successful or, if it was not, tells you which Connection-tab value is incorrect.
This option defers automatic commit operations while cursors remain open and can reduce database communication when the application is using non-ANSI logging databases. This option is available only as a connection option:
SQL_INFX_ATTR_OPTIMIZE_AUTOCOMMIT
or as a connection attribute string:
"OptimizeAutoCommit"
The default is: 1 (enabled).
This option causes the driver to buffer the open, fetch, and close cursor messages to the server. In addition, this option eliminates one or more message round trips when you use SQLPrepare, SQLExecute, and SQLFetch statements to fetch data with a cursor. This option is available only as a connection option:
or as a connection attribute string:
"OPTOFC"
The default is: 0 (disabled).
This option reduces the number of network messages sent to and from the server by buffering the inserted rows that are used with arrays of parameters and insert statements. This option can greatly improve the performance of bulk insert operations, and is available as both connection and statement options:
SQL_INFX_ATTR_ENABLE_INSERT_CURSORS.
or as a connection attribute string:
"EnableInsertCursors"
The default is: 0 (disabled).
If this option is activated, IBM Informix ODBC Driver, Version 2.90, supports only scrollable, static cursors. This option is available only as a connection option:
SQL_INFX_ATTR_ENABLE_SCROLL_CURSORS
or as a connection attribute string:
"EnableScrollableCursors"
The default is: 0 (disabled).
This option causes the driver to report (through SQLGetInfo) that it supports forward-only, static, and keyset-driven cursor types, although the driver only supports forward-only and static cursors. When you set this option, the driver enables dynaset-type functions, such as Microsoft's Visual Basic. These functions require drivers that support keyset-driven cursor types. This option is also available as a connection attribute:
SQL_INFX_ATTR_REPORT_KEYSET_CURSORS
or as a connection attribute string:
"ReportKeysetCursors"
The default is: 0 (disabled).
If you activate this feature, the driver causes SQLGetTypeInfo to map all occurrences of user-defined types (UDTs) as follows:
The driver maps multiset, set, row, and list data types to SQL_C_CHAR or SQL_C_BINARY, which is the default UDT
FetchType to SQL_C_CHAR features.The default is: 0 (disabled).
This option describes all floating-point decimal columns as Float (SQL_REAL or SQL_DOUBLE). A floating-point decimal column is a column that was created without a scale, ex: DECIMAL(12). Some prepackaged applications such as Visual Basic can not properly format Decimal columns that do not have a fixed scale. To use these applications you must enable this option or re-define the column with a fixed scale.
There is a disadvantage to enabling this option however, SQL_DECIMAL is an exact numeric data type while SQL_REAL and SQL_DOUBLE are approximate numeric data types. A SQL_DECIMAL with a precision of 8 or less will be described as SQL_REAL, with a precision greater than 8 it is SQL_DOUBLE.
The default is: 0 (disabled).
Causes SQLGetTypeInfo to not report LVARCHAR as a supported type of DATA_TYPE of SQL_VARCHAR.
Some applications such as MS Access97 will use LVARCHAR instead of VARCHAR even for columns that are less than 256 bytes long. The minimum number of bytes transmitted for LVARCHAR is higher than for Varchar and a large number of LVARCHAR columns can result in the rowset size exceeding the maximum. Enable this option only if your SQL_VARCHAR columns are less than 256 bytes in length.
The default is: 0 (disabled)
Causes SQLDescribeCol to report char columns as wide char columns. SQL_CHAR column is reported as SQL_WCHAR, SQL_VARCHAR as SQL_WVARCHAR and SQL_LONGVARCHAR column as SQL_WLONGVARCHAR
The default is: 0 (disabled)
When your application connects to this DSN, the values that you entered are the default entries for the DSN connection.
After you complete these steps, you will connect to the DSN.
Choose the File DSN option to allow access to the DSN to all users on a network. For a description of values, see Table 5 and Table 6.
The Create New Data Source wizard appears.
If you do not know the name of the file, click Browse to display the Save As dialog box and enter the values, as the following example shows:
Select a filename or type a filename in the File_name text box.
The name of the data file that you chose or typed in step 6 appears in the text box.
After you add or change DSN-configuration information, the driver updates the appropriate Windows registry to reflect the specified values. To be compatible with other IBM Informix connectivity products, the driver stores the DSN-configuration information in the Windows registry.
Choose a file or type a filename in the File_name text box.
After you complete these steps, you will connect to the DSN.
Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]