Commit graph

346 commits

Author SHA1 Message Date
Nickolay Ponomarev
bbf1805729 Support SELECT DISTINCT 2019-04-20 14:21:26 +03:00
Nickolay Ponomarev
31b6076d05 Use the same order in #[derive()] for all AST types
(So that adding another trait can be done with a global search and replace.)
2019-04-20 14:21:26 +03:00
Nickolay Ponomarev
e113dee7e8 Fix error text for unexpected token after NOT 2019-04-20 14:21:26 +03:00
Nickolay Ponomarev
5263ee1e9e Reduce nesting of ifs in SQLType::Decimal::to_string() 2019-04-20 14:21:26 +03:00
Nickolay Ponomarev
451513db5b Simplify parse_function() 2019-04-20 14:21:26 +03:00
Andy Grove
d9591cd999
Merge pull request #46 from zhzy0077/feature/external_table
Thanks @zhzy0077 !
2019-04-13 11:32:38 -06:00
Zhiyuan Zheng
d8f824c400 merge CreateExternalTable & CreateTable. 2019-04-14 01:05:26 +08:00
Zhiyuan Zheng
35556593f5
Delete test sql file. 2019-04-11 10:53:33 +08:00
Zhiyuan Zheng
26940920ac Add unit tests. 2019-04-09 13:28:01 +08:00
Zhiyuan Zheng
f0f6082eff support create external table 2019-04-08 21:36:02 +08:00
Andy Grove
d1b5668fd3
Merge pull request #43 from nickolay/master 2019-04-02 21:27:30 -06:00
Nickolay Ponomarev
311f2ab429 bump version to 0.3.0, as requested in the PR 2019-04-02 09:46:21 +03:00
Nickolay Ponomarev
5de23b1e78 Merge branch 'upstream' 2019-04-02 09:16:51 +03:00
Nickolay Ponomarev
6dfe7c2413 reapply the "Rework keyword/identifier parsing" PR 2019-04-02 09:15:15 +03:00
Andy Grove
bebaec4c79
Merge pull request #45 from andygrove/update_gitter_badge
Update badge based on gitter email
2019-03-31 22:54:06 -06:00
Andy Grove
eee1b3a2bd Update badge based on gitter email 2019-03-31 22:53:08 -06:00
Nickolay Ponomarev
5ba9912a9d Merge remote-tracking branch 'upstream/master' 2019-03-08 17:29:54 +03:00
Andy Grove
aa1f0faad4 (cargo-release) start next development iteration 0.2.5-alpha.0 2019-03-08 07:28:37 -07:00
Andy Grove
30de48c840 (cargo-release) version 0.2.4 2019-03-08 07:28:29 -07:00
Andy Grove
4a355e6ddc
Merge pull request #42 from andygrove/revert-37-keywords
Revert "Rework keyword/identifier parsing"
2019-03-08 07:28:07 -07:00
Andy Grove
43f4c6875f
Revert "Rework keyword/identifier parsing" 2019-03-08 07:27:27 -07:00
Andy Grove
391c53d5c9 (cargo-release) start next development iteration 0.2.4-alpha.0 2019-03-08 07:20:19 -07:00
Andy Grove
6580bf10c0 (cargo-release) version 0.2.3 2019-03-08 07:20:08 -07:00
Andy Grove
75e2c0a64f
Merge pull request #37 from nickolay/keywords
Rework keyword/identifier parsing
2019-03-08 07:19:34 -07:00
Andy Grove
7c9f62962d
Merge branch 'master' into keywords 2019-03-08 06:24:24 -07:00
Andy Grove
8c1d6a67fa (cargo-release) start next development iteration 0.2.3-alpha.0 2019-03-08 06:15:48 -07:00
Andy Grove
15704f1fbe (cargo-release) version 0.2.2 2019-03-08 06:15:37 -07:00
Andy Grove
73f55fe1bb
Merge pull request #36 from nickolay/strings
Clean up string-related variants in Token and Value
2019-03-08 06:14:59 -07:00
Andy Grove
ff897b9086
Merge pull request #38 from nickolay/remove-duplicate-tests
Remove sqlparser_generic.rs/sqlparser_postgres.rs duplication
2019-03-08 06:09:25 -07:00
Nickolay Ponomarev
0621f8d43c Merge https://github.com/nickolay/sqlparser-rs/pull/1 from benesch/materialized 2019-03-08 15:49:53 +03:00
Nickolay Ponomarev
f30ab89ad2 Re-run cargo fmt 2019-03-08 15:46:40 +03:00
Nikhil Benesch
23a0fc79f5
Support CREATE MATERIALIZED VIEW 2019-03-07 13:14:33 -05:00
Nickolay Ponomarev
52e0f55b6f Support UNION/EXCEPT/INTERSECT 2019-02-11 05:14:36 +03:00
Nickolay Ponomarev
533775c0da Support CHAR synonym for CHARACTER
https://jakewheat.github.io/sql-overview/sql-2011-foundation-grammar.html#character-string-type
2019-02-11 05:14:34 +03:00
Nickolay Ponomarev
23a0d032bd Support NUMERIC without precision or scale
https://jakewheat.github.io/sql-overview/sql-2011-foundation-grammar.html#exact-numeric-type
2019-02-11 05:13:48 +03:00
Nickolay Ponomarev
54c9ca8619 Support unary + / - 2019-02-11 05:13:48 +03:00
Nickolay Ponomarev
786b1cf18a Support BETWEEN 2019-02-11 05:13:48 +03:00
Nickolay Ponomarev
264319347d Support IN 2019-02-11 05:13:48 +03:00
Nickolay Ponomarev
bed03abe44 Support AS and qualified wildcards in SELECT 2019-02-11 05:13:48 +03:00
Nickolay Ponomarev
bf0c07bb1b Support basic CTEs (WITH)
Some unsupported features are noted as TODOs.
2019-02-11 05:13:48 +03:00
Nickolay Ponomarev
f958e9d3cf TBD fixup multiline comment tokenization 2019-02-11 05:13:48 +03:00
Nickolay Ponomarev
028c613c3f Support comments in the tokenizer 2019-02-07 05:34:38 +03:00
Nickolay Ponomarev
35dd9342e2 Support national string literals (N'...')
Widely used in MS SQL and specified in ANSI.
2019-02-07 05:34:33 +03:00
Nickolay Ponomarev
b9f4b503b6 Support different quoting styles for delimited identifiers
The dialect information is from https://en.wikibooks.org/wiki/SQL_Dialects_Reference/Data_structure_definition/Delimited_identifiers
2019-02-07 05:34:29 +03:00
Nickolay Ponomarev
b3693bfa63 Simplify quoted identifier tokenization 2019-02-07 05:34:26 +03:00
Nickolay Ponomarev
2e9da53ed3 Small CLI app that can be used to test parsing an external SQL file 2019-02-07 05:34:16 +03:00
Nickolay Ponomarev
577e634f3c Update README to the recent changes in the AST 2019-02-07 05:34:16 +03:00
Nickolay Ponomarev
0c0cbcaff4 Support basic CREATE VIEW 2019-02-07 05:34:12 +03:00
Nickolay Ponomarev
346d1ff2e4 Improve error messages in parse_create()
By not swallowing the Err from parse_data_type().

Also switch to `match` to enable parsing table-level constraints in this
loop later.
2019-02-07 05:34:09 +03:00
Nickolay Ponomarev
a0f625b949 Simplify parse_create() a little
Don't need the duplicate `columns.push()` + we advance the tokenizer,
so no need to peek first.
2019-02-07 05:34:06 +03:00