Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[0.9.4.1] DROP SERIES with a regex for the measurement matches every measurement #4276

Closed
beckettsean opened this issue Sep 29, 2015 · 2 comments
Assignees
Milestone

Comments

@beckettsean
Copy link
Contributor

DROP SERIES FROM /regex/ doesn't throw a parser error, but it also doesn't process the regex correctly, and appears to match every series regardless of the actual regex:

First set up some trivial points:

> select * from /.*/
name: a
-------
time                value
2015-09-29T23:38:05.053831883Z  1


name: aa
--------
time                value
2015-09-29T23:38:16.5497425Z    1


name: b
-------
time                value
2015-09-29T23:38:10.365167564Z  1


name: bb
--------
time                value
2015-09-29T23:38:20.158076911Z  1


name: c
-------
time                value
2015-09-29T23:38:23.318307Z 1


name: cc
--------
time                value
2015-09-29T23:38:24.766492625Z  1

Now drop a particular series:

> drop series from aa
> select * from /aa/
> select * from /.*/
name: a
-------
time                value
2015-09-29T23:38:05.053831883Z  1


name: b
-------
time                value
2015-09-29T23:38:10.365167564Z  1


name: bb
--------
time                value
2015-09-29T23:38:20.158076911Z  1


name: c
-------
time                value
2015-09-29T23:38:23.318307Z 1


name: cc
--------
time                value
2015-09-29T23:38:24.766492625Z  1

So far so good. Now let's drop a regex set of series:

> drop series from /a/
> select * from /.*/
> show series
> 

Suddenly every point for every series is gone, even the ones that cannot match /a/.

@beckettsean beckettsean changed the title [0.9.4.1] DROP SERIES with a regex drops too much data [0.9.4.1] DROP SERIES appears to ignore the WHERE clause entirely Oct 2, 2015
@beckettsean beckettsean changed the title [0.9.4.1] DROP SERIES appears to ignore the WHERE clause entirely [0.9.4.1] DROP SERIES appears to ignore the WHERE clause for regex and/or fields Oct 2, 2015
@beckettsean beckettsean changed the title [0.9.4.1] DROP SERIES appears to ignore the WHERE clause for regex and/or fields [0.9.4.1] DROP SERIES with a regex for the measurement matches every measurement Oct 2, 2015
@beckettsean
Copy link
Contributor Author

Should be addressed at the same time as #4280

@dgnorton
Copy link
Contributor

dgnorton commented Oct 6, 2015

Looked at #4280 and it's unrelated.

dgnorton added a commit that referenced this issue Oct 6, 2015
fix #4276: shouldn't drop all series when regex doesn't match
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants