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

[Bug] The NOT unary prefix operator returns a 305 internal server error. #13725

Open
2 tasks done
LingweiKuang opened this issue Oct 11, 2024 · 1 comment
Open
2 tasks done

Comments

@LingweiKuang
Copy link

LingweiKuang commented Oct 11, 2024

Search before asking

  • I searched in the issues and found nothing similar.

Version

+-------+---------+
|Version|BuildInfo |
+-------+---------+
| 1.3.2| aa0ff4a |
+-------+---------+

Describe the bug and provide the minimal reproduce step

DROP DATABASE root.db0
CREATE DATABASE root.db0

INSERT INTO root.db0(t1) VALUES (1)
INSERT INTO root.db0(timestamp, t1) VALUES (13453556, 2)
INSERT INTO root.db0(timestamp, t1) VALUES (1519786882, 3)

# query 1
SELECT t1 FROM root.db0 WHERE !(2 + 50)
SELECT t1 FROM root.db0 WHERE !(2 / 50)

# query 2
SELECT t1 FROM root.db0 WHERE !100

What did you expect to see?

Query 1 and Query 2 should return the same error message.

What did you see instead?

Query 1 returns Msg: 305: [INTERNAL_SERVER_ERROR(305)] Exception occurred: "SELECT t1 FROM root.db0 WHERE !(2 + 50)". executeStatement failed. Unsupported expression type: ADDITION error. Query 2 returns Msg: 701: Invalid input expression data type. expression: 100, actual data type: INT64, expected data type(s): [BOOLEAN]. error.

Anything else?

Dear IoTDB team, I believe the 305 internal error returned by Query 1 should be classified as a logical bug, as it may lead to user misunderstanding.In Query 1, besides addition, other binary arithmetic operators also exhibit the same vulnerability. If it is a bug, please mark this issue as "bug". Thank you!

Are you willing to submit a PR?

  • I'm willing to submit a PR!
Copy link

Hi, this is your first issue in IoTDB project. Thanks for your report. Welcome to join the community!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant