Skip to content

Specify dialect per external model #3135

@markgraphene

Description

@markgraphene

Issue
As per the duckdb example configuration (https://sqlmesh.readthedocs.io/en/stable/integrations/engines/duckdb/?h=duck#duckdb-catalogs-example) it is possible to attach a variety of data catalogs, however if specifying these as external tables there is no way to specify the dialect for each external table - ie. you may have an external model sqlite.main.example and another model postgres.public.example2, which should each be specified as per their dialect.
Currently the only way to specify the dialect for external tables is via model_defaults.

gateways:
  my_gateway:
    connection:
      type: duckdb
      catalogs:
        memory: ':memory:'
        sqlite:
          type: sqlite
          path: 'test.db'
        postgres:
          type: postgres
          path: 'dbname=postgres user=postgres host=127.0.0.1'
          read_only: true

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions