Odbc@1

Odbc@1 Provider lets you read data from an ODBC source.

Odbc@1 provider works out-of-the-box, you don’t need any drivers installed.

Example

Data sources:
- Name: MyOdbcData
  Provider: Odbc@1
  Connection string: DSN=AERO_DWH

The example assumes you already have a 64-bit ODBC entry named AERO_DWH.

Storing Test definitions and Data Source definitions in DB

Reading and testing data is not the only purpose of providers. You can also use them for retrieving (potentially also automatically generating) test defintions and / or data sources. This is valid also for ODBC provider. Any SQL statement that returns columns expected by Test definition or Data source defintition will work.

You may want to persist the test definitions in a table. The SQL syntax depends on the database you are connecting to, so the scripts here serve only as a clue what you might need to create. (It is actually PostgreSQL syntax.)

CREATE TABLE test.cat_test_definition(
  "test_suite" VARCHAR(300) NULL,
  "order" INT NULL,
  "test_case" VARCHAR(300) NULL,
  "test_name" VARCHAR(300) NOT NULL,
  "description" TEXT NULL,
  "first_data_source" VARCHAR(200) NULL,
  "first_query" TEXT NULL,
  "second_data_source" VARCHAR(200) NULL,
  "second_query" TEXT NULL,
  "expectation" VARCHAR(50) NOT NULL,
  "categories" VARCHAR(100) NULL,
  "tolerance" DECIMAL(19, 4) NULL,
  "timeout" INT NULL,
  "key"  VARCHAR(100) NULL,
  "maximum_errors_logged" INT NULL
);
CREATE TABLE test.cat_connection_definition(
  "name" VARCHAR(200) NOT NULL,
  "provider" VARCHAR(200) NOT NULL,
  "connection_string" VARCHAR(2000) NOT NULL
);

Just fill them up with data and let CAT know about them (see Project files).