DerekStride / tree-sitter-sql

SQL grammar for tree-sitter
http://derek.stride.host/tree-sitter-sql/
MIT License
147 stars 47 forks source link

Support for check constraints #247

Closed rliebz closed 4 months ago

rliebz commented 4 months ago

The parser does not currently seem to support check constraints, for example:

CREATE TABLE products (
    product_no integer,
    name text,
    price numeric CHECK (price > 0)
);

For reference: https://www.postgresql.org/docs/current/ddl-constraints.html#DDL-CONSTRAINTS-CHECK-CONSTRAINTS

matthias-Q commented 4 months ago

If I have time I will take a look.