Installation and Setup
Install and register the GridGain 9 ODBC driver on Windows and Linux, configure the cluster, and use it with tools such as pyodbc.
Overview
GridGain 9 includes an ODBC driver that allows you both to select and to modify data stored in a distributed cache by using standard SQL queries and native ODBC API. ODBC driver uses your client connection configuration.
ODBC driver only provides thread-safety at the connections level. This means that you should not access the same connection from multiple threads without additional synchronization, though you can create separate connections for every thread and use them simultaneously.
The ODBC driver implements version 3.8 of the ODBC API. For detailed information on ODBC please refer to ODBC Programmer's Reference.
Installing ODBC Driver
To use ODBC driver, register it in your system so that your ODBC Driver Manager will be able to locate it.
Installing on Windows
Prerequisites
Microsoft Visual C++ 2017 Redistributable Package should be installed first.
Installation process
Launch the provided installer and follow the instructions.
Configuring the Cluster
ODBC driver uses the client connector to work with the cluster. Make sure to configure the port to the one you intend to use, for example:
For more information on configuring client connector, see Client Connector Configuration.
Installing on Linux
To build and install ODBC driver on Linux, you need to first install ODBC Driver Manager. The ODBC driver has been tested with UnixODBC.
Prerequisites
Install the following first:
Download from website
You can get the built rpm or deb package from the provided website. Then, install the package locally to use it.
Supported Data Types
The following SQL data types are supported:
SQL_CHARSQL_VARCHARSQL_LONGVARCHARSQL_SMALLINTSQL_INTEGERSQL_FLOATSQL_DOUBLESQL_BITSQL_TINYINTSQL_BIGINTSQL_BINARYSQL_VARBINARYSQL_LONGVARBINARYSQL_GUIDSQL_DECIMALSQL_TYPE_DATESQL_TYPE_TIMESTAMPSQL_TYPE_TIME
Using pyodbc
GridGain can be used with pyodbc. Here is how you can use pyodbc in GridGain 9:
Install pyodbc:
Import pyodbc to your project:
Connect to the database:
Set encoding to UTF-8:
Get data from your database:
For more information on using pyodbc, use the official documentation.
Last updated
Was this helpful?

