The problem I’m having / What I’ve already tried
Running into a SQL syntax error when trying to export a saved_query
as a table, rather than a view.
When setting the configuration of the export with export_as: view
, running dbt sl export --saved-query <query_name>
runs successfully and the view is materialized in my data source.
Upon changing the config to export_as: table
, an error is thrown:
Export failed with error:
INVALID_ARGUMENT: [FlightSQL] ERROR: syntax error at or near "TABLE"
Position: 19 (InvalidArgument; Prepare)
Polling completed
The dbt exports are being run against our Redshift instance, and seems to be running into some kind of syntax error with this dialect of SQL from the export logic on the backend of dbt.
Connection type: redshift
dbt version: 1.7.0-latest