Menu
Simba Technologies
Simba Technologies

Simba MongoDB ODBC Driver with SQL Connector 2.2.3
Installation and Configuration Guide

Simba > Drivers > MongoDB > ODBC Installation Guide > Windows > Configuration > Configuring Advanced Options

Configuring Advanced Options

You can configure advanced options to modify the behavior of the driver.

For detailed information about the options on this page, see Advanced Driver Configuration Options

To configure advanced options:

  1. To access advanced options, open the ODBC Data Source Administrator where you created the DSN, then select the DSN, then click Configure, and then click Advanced Options.
  2. To retrieve data using double-buffering instead of single-buffering, select the Enable Double-Buffering check box. You can configure the buffer size using the Documents to fetch per block field.
  3. In the Documents to fetch per block field, type the maximum number of documents that a query returns at a time. This setting also determines the buffer size used when double-buffering is enabled.
  4. To return MongoDB String data as SQL_WVARCHAR instead of SQL_VARCHAR, select the Expose Strings as SQL_WVARCHAR check box.
  5. In the String Column Size field, type the maximum data length for String columns.
  6. To return MongoDB Binary data as SQL_LONGVARBINARY instead of SQL_VARBINARY, select the Expose Binary as SQL_LONGVARBINARY check box.
  7. In the Binary Column Size field, type the maximum data length for Binary columns.
  8. To configure the driver to optimize joins between virtual tables and pass filtering and aggregation optimizations to the MongoDB database for handling, select the Enable Passdown check box.
  9. Use the options in the Metadata area to specify the schema definition to use when connecting to the database:
    • To configure the driver to use a schema definition stored in a JSON file, select Local File from the Mechanism drop-down list, and then click Browse and select the JSON file that you want to use.
    • To configure the driver to use a schema definition stored in the MongoDB database that you are connecting to, in the Mechanism drop-down list, select Database.

    Note:

    For information about how to create a schema definition using the Schema Editor application, see the Schema Editor User Guide located in the installation directory of the driver.

    • On Windows 7 or earlier, the guide is available from the Simba MongoDB ODBC Driver program group in the Start menu.
    • On Windows 8 or later, you can search for the guide on the Start screen.
  10. Use the options in the Sampling area to configure how the driver samples data to generate temporary schema definitions:
    1. In the Sampling Method list, select the direction in which the driver reads data during sampling. For example, if you select Forward, the driver samples data starting from the first record in the database, then samples the next record, and so on.
    2. In the Documents to sample field, type the maximum number of documents that the driver can sample to generate the schema definition. To sample every document in the database, type 0.

    Important:

    • Make sure to configure the driver to sample all the necessary data. Documents that are not sampled do not get included in the schema definition, and consequently do not become available in ODBC applications.
    • Typically, sampling a large number of documents results in a schema definition that is more accurate and better able to represent all the data in the database. However, the sampling process may take longer than expected when many documents are sampled, especially if the database contains complex, nested data structures.
  11. In the Step Size field, type the interval at which the driver samples a record when scanning through the database. For example, if you set this option to 2, then the driver samples every second record in the database starting from the first record.
  12. To configure write-back behavior in the driver, click Writeback Options. For more information, see Configuring Write-Back Options.
  13. To save your settings and close the Advanced Options dialog box, click OK.
  14. To close the Simba MongoDB ODBC Driver DSN Setup dialog box, click OK.