Daniel Morsing
fc4246d7f5
be more strict about identifier printing
...
When stringifying a query, we would print the identifier bare most
of the time. This caused issues when stringifying an identifier
that contained elements of syntax. For example, querying for the
value "in-bytes" would fail because the mapper would serialize it to
in-bytes and would parse it as an expression. Same problem occured
when using keywords as identifier names, such as select or in.
Fixes #3547
2015-08-05 17:40:42 +01:00
Daniel Morsing
6797270403
check if fields are valid during parse.
...
Binary expressions that yield a boolean are invalid and we can catch
these at parse time.
Fixes #3525
2015-08-04 16:02:35 +01:00
gunnaraasen
eca76ed7a3
Parser fix, only allow ORDER BY clause with time ASC
2015-07-21 12:07:56 -07:00
Philip O'Toole
f549910a18
Merge pull request #3279 from LK4D4/fix_style_else
...
Fix style issues with else
2015-07-17 11:53:42 -07:00
gunnaraasen
9ba37325f6
Fixes authorization.
...
Adds GRANT and REVOKE statements for admin privilege. Adds authorization to the query endpoint.
2015-07-17 11:33:06 -07:00
Alexander Morozov
675eacbf2c
Fix style issues with else
...
In go it's better to just continue flow without "else", if it is return in
"if" statement.
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-07-17 11:10:23 -07:00
Robert Nubel
930a1aa523
Require a regex after a regex operator when parsing.
...
Previously, parseRegex could return an empty RegexLiteral
and the expression parser would put that into the right-hand
side of the expression, causing a nil-pointer panic when
the query was later executed. This change adds a check at
the parsing level and returns an error message if a regex
operator (e.g. =~) is not followed by an actual regex.
2015-07-17 11:02:45 -07:00
gunnaraasen
ee8ba11c4f
Add ON token to SHOW RETENTION POLICIES parser with tests
2015-07-16 13:45:50 -07:00
David Norton
debc3cc11c
fix #3102 : add authentication cache
2015-06-30 18:29:11 -04:00
Joseph Crail
5fccee3d16
Fix spelling errors in comments and strings.
2015-06-28 02:54:34 -04:00
Dejan Golja
f133ceb350
Added support for SHOW GRANTS FOR USER syntax
2015-06-17 01:00:26 +10:00
Philip O'Toole
cdf7188259
Only ORDER BY ASC is valid for now
...
Fix issue #2731
2015-06-11 00:51:44 -07:00
Paul Dix
4a1ce77090
Wire up DROP SERIES.
...
* Pulled over updates to ast and parser from master
* Updated store and shard to be able to drop series
* Pulled updates to database.go from master into tsdb/meta.go
2015-06-02 11:20:20 -04:00
Ben Johnson
75ab63b538
Refactor meta statement execution to meta.StatementExecutor.
2015-05-29 14:54:04 -06:00
Cory LaNou
fc7d63ce61
validate methods can be private
2015-05-19 09:16:21 -06:00
Cory LaNou
b9de38e7d4
support SELECT DISTINCT foo and SELECT distinct(foo)
2015-05-19 09:16:20 -06:00
Cory LaNou
06d40a2582
SELECT DISTINCT field -> SELECT distinct(field)
2015-05-19 09:16:20 -06:00
Cory LaNou
b6b916edbc
add distinct keyword
2015-05-19 09:16:19 -06:00
Cory LaNou
bfdf05033d
refactor validating select statement
2015-05-12 08:42:39 -06:00
Cory LaNou
93760c8679
update comment and changelog for count -> aggregate
2015-05-11 18:00:59 -06:00
Cory LaNou
cebdfea737
any aggregate function that has a group by time without a where time clause should fail
2015-05-11 17:48:37 -06:00
Cory LaNou
0155f8bb6d
hasWhereTime -> hasTimeDimensions
2015-05-11 17:48:21 -06:00
Cory LaNou
832ca01cd3
learn to spell claus
2015-05-11 17:48:21 -06:00
Cory LaNou
892a6e831b
error out for invalid count group select without where time
2015-05-11 17:48:21 -06:00
ben hockey
ce54004961
normalize Call.Name to be lowercase
2015-05-01 12:05:55 -05:00
David Norton
66b8cc02aa
fix #2268 : code review changes
2015-04-15 13:52:18 -04:00
David Norton
1e7b132f96
fix #2268 : make ugly code pretty
2015-04-15 13:25:49 -04:00
David Norton
3739433f0c
fix #2268 : fix expression parsing bug
...
Parsing:
WHERE time > now() - 2d AND time < now() + 10d
generated an expression tree that evaluated as:
... AND (time < now()) + 10d
instead of:
... AND time < (now() + 10d)
2015-04-15 12:37:19 -04:00
Todd Persen
ebd8ca7016
Merge pull request #2191 from influxdb/calls_case
...
Case-insensitive check for "fill"
2015-04-13 12:13:43 -07:00
Philip O'Toole
bf1a8aa1e4
Use uint64 for Series IDs
...
Fixes issue #1649
2015-04-10 16:11:34 -07:00
David Norton
a67e9a8a95
fix #2215 : allow keyword default to be unquoted
...
InfluxDB creates a default retention policy named "default". DEFAULT is
also a keyword in the language. This required double quoting "default"
in the ALTER RETENTION POLICY statement. This commit makes the parser
accept it unquoted for that one statement.
2015-04-09 16:37:20 -04:00
David Norton
25cea58635
refactor scanning & parsing of identifiers
2015-04-09 13:21:13 -04:00
Philip O'Toole
f5b769781b
Case-insensitive check for "fill"
2015-04-07 19:21:37 -07:00
Dejan Golja
e1b9982401
Add support for SET PASSWORD FOR user = 'PASSWORD'
...
Added support for the set password for user, so we can update user
password via the new server administration commands
2015-04-04 14:16:54 +11:00
Todd Persen
94a8019fc7
Wire up DROP CONTINUOUS QUERY
2015-03-25 11:58:33 -07:00
Philip O'Toole
1c440f8542
Implement "SHOW DIAGNOSTICS"
2015-03-23 23:45:57 -07:00
Cory LaNou
e2f33e354f
clarify error message
2015-03-20 16:52:32 -06:00
Cory LaNou
3c8e830aa3
fixing tests
2015-03-20 16:51:41 -06:00
Cory LaNou
dc0d8a35dc
wip
2015-03-20 16:51:41 -06:00
Philip O'Toole
dc297e8012
Correctly use IsRawQuery
2015-03-19 16:32:25 -07:00
Philip O'Toole
59f25910c6
IsRawQuery should be set via Walk()
2015-03-19 16:26:16 -07:00
Philip O'Toole
b045a0008e
Remove redundant Aggregated() on select statement
2015-03-19 15:22:43 -07:00
Philip O'Toole
cbd43bd9b2
IsRaw now works without time present
2015-03-19 15:12:46 -07:00
Paul Dix
56281fbfd5
WIP: add IsRawQuery to select and fix LIMIT and OFFSET on GROUP BY time
2015-03-19 11:41:18 -04:00
David Norton
fd005a5f15
influxql: allow regex in FROM clause
2015-03-16 19:40:21 -04:00
Philip O'Toole
e08066495a
Add "SHOW STATS" command
2015-03-15 14:31:16 -07:00
Cory LaNou
08b15d9370
zeros are ok after all
2015-03-12 18:59:38 -06:00
Cory LaNou
eda74a25f1
allow offset 0
2015-03-12 18:20:58 -06:00
Paul Dix
06e8c1b3e8
Add fill to select statements.
...
Fixes #1913
Add fill(none), fill(<num>), and fill(previous) options
2015-03-11 18:05:31 -07:00
Cory LaNou
de1defc528
add SHOW SERVERS to query language
2015-03-10 13:46:05 -06:00