Nickolay Ponomarev
bf3110f6ce
Use consume_and_return
when possible
2019-04-27 02:51:10 +03:00
Nickolay Ponomarev
6f44494910
Support \r and \r\n line breaks in tokenizer
2019-04-26 02:53:39 +03:00
Justin Haug
76d2d46496
run cargo fmt
2019-04-22 18:06:00 -04:00
Justin Haug
f9fb4bedfb
Move wildcard test to generic parser
2019-04-22 17:52:15 -04:00
Justin Haug
80aceba630
run cargo fmt
2019-04-22 17:50:12 -04:00
Justin Haug
80dccf6885
Add support for escaping single quote strings
2019-04-22 13:32:05 -04:00
Justin Haug
5b464e6b1a
Fix qualified wildcard stringifying
2019-04-22 13:10:29 -04:00
Nickolay Ponomarev
098d1c4a17
Enable clippy lints by default in RLS
2019-04-21 04:46:19 +03:00
Nickolay Ponomarev
50a2310173
Rename SQLStatement::SQLSelect to SQLQuery
...
The name was confusing:
SQLStatement::SQLSelect(
SQLQuery {
body: SQLSetExpr::Select(SQLSelect)
}
)
Fix the `large_enum_variant` clippy lint for `SQLStatement::SQLQuery`
`SQLStatement::SQLCreateView`, and `SQLSetExpr::Select`, while we're
changing the AST anyway
https://rust-lang.github.io/rust-clippy/master/index.html#large_enum_variant
2019-04-21 04:46:19 +03:00
Nickolay Ponomarev
08bbce8992
Use assert_matches! instead of matching manually
...
To fix clippy warnings about assert!(true / false)
2019-04-21 04:46:19 +03:00
Nickolay Ponomarev
dee30aabe0
Fix the clippy assert!(false)
lint
...
https://rust-lang.github.io/rust-clippy/master/index.html#assertions_on_constants
While I don't feel it's valid, fixing it lets us act on the other, more
useful, lints.
2019-04-21 04:46:19 +03:00
Nickolay Ponomarev
a3a8626e6b
Fix a clippy lint and reduce duplication in SQLType::to_string()
2019-04-21 04:46:19 +03:00
Nickolay Ponomarev
c223eaf0aa
Fix a bunch of trivial clippy lints
2019-04-21 04:46:19 +03:00
Nickolay Ponomarev
3df2223d95
Fix clippy if_same_then_else lint
...
https://rust-lang.github.io/rust-clippy/master/#if_same_then_else
There was a bug in parsing `TIME` (not followed by {WITH | WITHOUT}
TIME ZONE) -- that parsed as SQLType::Timestamp instead of SQLType::Time
2019-04-21 04:41:11 +03:00
Nickolay Ponomarev
0634ec4a83
Apply suggestions from cargo fix --edition-idioms
2019-04-21 04:41:11 +03:00
Nickolay Ponomarev
b12a19e197
Switch to the Rust 2018 edition
...
This requires Rust 1.31 (from last year) to build, but is otherwise
compatible with the 2015-edition code.
2019-04-21 04:41:11 +03:00
Nickolay Ponomarev
9a244e059e
Fix clippy lints in "Support qualified function names"
2019-04-21 02:05:36 +03:00
Nickolay Ponomarev
de057deff6
Fix clippy lints in comma_separated_string
2019-04-21 02:05:36 +03:00
Nickolay Ponomarev
8c7e1d1c54
Update sample output in README
2019-04-20 22:51:29 +03:00
Nickolay Ponomarev
085e8a6b04
Use named fields in ExpressionWithAlias instead of a tuple
...
(This produces more natural JSON representation when serializing AST
with serde.)
2019-04-20 22:51:29 +03:00
Nickolay Ponomarev
4a5dc8dd4b
Support qualified function names
...
...e.g. `db.schema.func()`
2019-04-20 22:51:29 +03:00
Nickolay Ponomarev
d4de248c73
Support OVER clause for window/analytic functions
...
Since this changes SQLFunction anyway, changed its `id` field to `name`,
as we don't seem to use "id" to mean "name" anywhere else.
2019-04-20 22:51:29 +03:00
Nickolay Ponomarev
c8e7c3b343
Introduce comma_separated_string() to reduce boilerplate in ToString impls
2019-04-20 22:51:29 +03:00
Andy Grove
ef76baa7fd
(cargo-release) start next development iteration 0.3.1
2019-04-20 07:33:37 -06:00
Andy Grove
1aa4733890
bump version
2019-04-20 07:33:21 -06:00
Andy Grove
6ebd5dd819
Merge pull request #49 from nickolay/select-distinct
...
Support SELECT DISTINCT, and a few minor tweaks
2019-04-20 07:26:13 -06:00
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 if
s 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