Data source configuration file (UNIX and Linux®)
The driver manager and the ODBC drivers use the .odbc.ini configuration file to get information about data sources.
You normally place the .odbc.ini file in your own home directory. The period precedes the file name only when the file is in your home directory.
Database
- The name of the system database on the Netezza Performance Server system.
SchemaName
- The name of the schema within the specified database on the Netezza Performance Server system. This field is used for Netezza Performance Server systems that support multiple schemas within a database. If you do not specify a schema, you connect to the default schema of the database.
User name
- A valid user ID for accessing the system data source.
Server name
- The server host name or IP address of your Netezza Performance Server system.
Password
- A valid password for accessing the system data source.
The following example shows the contents of the odbc.ini.sample file, which
is in the /usr/local/nz/lib/ directory after you install your ODBC drivers. The
sample file describes a system data source that is found on every Netezza Performance Server system and includes comments that
explain each parameter. Use the contents of this sample file, along with the administrator
information that you substitute, to configure your own .odbc.ini file. Because
there can be differences between some source and target data types, add the
UnicodeTranslationOption=utf8
code to your .odbc.ini file to
prevent issues.
UnicodeTranslationOption=utf8
;
; odbc.ini
;
[ODBC Data Sources]
NZSQL = NetezzaSQL
[NZSQL]
;Path of a driver used for database connection
Driver = /usr/local/nz/lib/libnzodbc.so
;A decription used to identify the database connection properties.
Description = NetezzaSQL ODBC
;The name of a machine or IP address where the database is located.
Servername = 127.0.0.1
;The port number to connect.
Port = 5480
;The name of a database.
Database = dev
;The schema in the database. If unspecified, driver connects to
:default schema for the database.
SchemaName = sample_schema
;The name of a valid user.
Username = guest
;The password for the user.
Password = password
;Only Select SQL statements will be allowed if this field is checked.
ReadOnly = false
;When this option is enabled and the application bindtype is same as
;backend datatype the query performance will be faster. Query
;performance gain will be achieved only for single select statements
;(not for batch queries).It also works in case when application bind
;type is different than backend datatype but there are some
;restrictions on it.
FastSelect = false
;When set to true, system tables will be included in the available
table list.
ShowSystemTables = false
;When set to true, use old (2.5) functionality for returning schemas in
SQLTables.
LegacySQLTables = false
;Specifies login timeout in seconds.
LoginTimeout = 0
;Specifies query timeout in seconds.
QueryTimeout = 0
;Specifies date format as follows -
; 1: YMD
; 2: MDY
; 3: DMY
DateFormat = 1
;When selected, driver treats SQL_C_NUMERIC buffers as SQL_C_CHAR
buffers.
NumericAsChar = false
;Return SQL_BIT as "1"/"0" when char.
SQLBitOneZero = false
;When enabled, replaces all occurences of CRLF, CR and LF with a single
space.
StripCRLF = false
;Specifies level of security on the system
securityLevel = preferredUnSecured
;Name of the Root CA certificate.
caCertFile =
;Specifies maximum errors allowed. 0 value means no limit on
loadMaxErrors value.
;loadMaxErrors = 1
;If value is true, it rounds the data of numeric columns whose
precision exceeds the precision defined.
;loadRoundFraction = 0
[ODBC]
IANAAppCodePage=4
InstallDir=/opt/odbc32v51
Trace=0
TraceDll=/opt/odbc32v51/lib/odbctrac.so
TraceFile=odbctrace.out
UseCursorLib=0
The data source properties are explained in Configuring the DSN and driver options with ODBC Driver Setup. Use this information to help select appropriate values for the entries in your .odbc.ini file.