ODBC Driver for Google Sheets

Connection String Parameters - ODBC Driver for Google Sheets



ODBC Driver for Google Sheets ODBC Connection String Parameters

The following table lists the connection string parameters for ODBC Driver for Google Sheets.

Parameter Description

Refresh Token

The refresh token that authorizes the driver to access your ODBC Driver for Google Sheets data.

Spreadsheet

The name of the currently active google spreadsheet. You can use only one spreadsheet within one connection.

Spreadsheet Id

The unique id of the active spreadsheet consisting of the specific string of characters.

Proxy Settings

Proxy Server

The proxy hostname or IP address.

Proxy Port

The proxy port.

Proxy User ID

The proxy username.

Proxy Password

The proxy password.

Advanced Settings

Allow NULL Strings

To retrieve metadata, not all parameters according to MSDN can accept a null value. If NULL, the driver should return an error. But some 3rd-party tools pass NULL to the parameters. These options should be enabled for compatibility with such tools.

Empty Strings as NULL

ReturnForeignKeys

Use the option to specify whether the driver must return foreign keys. Retrieving metadata about foreign key constraints is a time-consuming operation; many third-party tools request foreign key metadata even whey they do not actually need this information. Note that enabling the option may degrade performance of data access operations. The default value is False.

Header As ColumnName

Specifies whether to use the first row of a spreadsheet to identify the column names. By default, the standard A-Z column names are used. The possible values are True and False. The default value is False.

Connection Timeout

The time (in seconds) to wait for a connection to open before terminating an attempt. The default value is 60.

QueryTimeout

The time to wait for a query execution result before terminating and generating an error.

UTC Dates

Specifies whether all the datetime values retrieved from the data source are returned as UTC values or converted to local time and whether the date values specified on the application side (e.g., in SQL statements) are considered UTC or local. The default value is false.

Max Cell Length

Specifies the maximum number of characters in a cell. The default value is 4000 characters.

RegionalNumberSettings

Enables the use of local regional settings when converting numbers to strings.

RegionalDateTimeSettings

Enables the use of local regional settings when converting dates and times to strings.

ODBC Behavior

Sets the behavior corresponding to the ODBC specification version expected by a third-party tool. The behavior of the ODBC driver can be changed by calling the SQLSetEnvAttr function to set the SQL_ATTR_ODBC_VERSION environment attribute. Some third-party tools expect the driver to exhibit ODBC 2.x behavior, but forget to call SQLSetEnvAttr with the needed version, or pass the incorrect value. In this case, the behavior can be explicitly set in the Connection String.
  • Default - The default value. The ODBC behavior is determined by a third-party tool.
  • Ver 2.x - ODBC 2.x behavior is explicitly set.
  • Ver 3.x - ODBC 3.x behavior is explicitly set.

String Types

Sets the string value types returned by the driver as Default, ANSI, or Unicode.
  • Default - The driver defines the string types.
  • Ansi - All string types are returned as SQL_CHAR, SQL_VARCHAR, and SQL_LONGVARCHAR.
  • Unicode - All string types are returned as SQL_WCHAR, SQL_WVARCHAR, and SQL_WLONGVARCHAR.

Set the parameter to Ansi or Unicode, if your third-party tool supports only Ansi or Unicode strings.

ODBC Driver for Google Sheets Connection String sample

DRIVER={Devart ODBC Driver for ODBC Driver for Google Sheets};Refresh Token=$F5Fh&%`1:bsxA`AK@VN*j)p&3D\fW>Y+R6`1fj'1Ee$0u#?MXs^5u>vr`1h1EJEZ]eGi9F;Spreadsheet=ODBC Docs Interlinking;Spreadsheet Id=1i69KtatwBKXFnIUNMmxv8uSpPSfqz2jhimJ

© 2015-2024 Devart. All Rights Reserved. Request Support ODBC Forum Provide Feedback