Skip to content

Conversation

de-luca
Copy link
Contributor

@de-luca de-luca commented Dec 20, 2023

Add support for configuration statement SET to the Postgres dialect.
Reference: https://www.postgresql.org/docs/current/sql-set.html

@@ -412,3 +412,16 @@ truncate_descendant ::= {table_name} ['*'] ( COMMA {table_name} ['*'] ) *
truncate_option ::= truncate_option_identity | truncate_option_cascade
truncate_option_identity ::= ( 'RESTART' | 'CONTINUE' ) 'IDENTITY'
truncate_option_cascade ::= 'CASCADE' | 'RESTRICT'

set_stm ::= 'SET' [ ('SESSION' | 'LOCAL') ] ( set_config | set_timezone | set_schema | set_names | set_seed )
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be set_stmt?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, my bad.
Fixed set and truncate statements.

@de-luca de-luca requested a review from eygraber January 4, 2024 09:27
Copy link
Collaborator

@hfhbd hfhbd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks.

@hfhbd hfhbd merged commit bf0005c into sqldelight:master Jan 5, 2024
@de-luca de-luca deleted the pg-set branch January 5, 2024 13:32
hfhbd pushed a commit that referenced this pull request Apr 2, 2024
* Add SET statement to pg dialect

* Fix statement name
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants