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

The NOT operator triggers a logical bug. #28336

Open
LingweiKuang opened this issue Oct 12, 2024 · 0 comments
Open

The NOT operator triggers a logical bug. #28336

LingweiKuang opened this issue Oct 12, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@LingweiKuang
Copy link

LingweiKuang commented Oct 12, 2024

Bug Description

The NOT operator triggers a logical bug.

To Reproduce

Assume that we execute the following statement under a database named testdb.

DROP TABLE IF EXISTS t1;
CREATE TABLE t1( time TIMESTAMP, c0 BIGINT , c1 BIGINT UNSIGNED);

INSERT INTO t1(time, c1) VALUES (1641024000000, NULL);
INSERT INTO t1(time, c1) VALUES (1641024000001, NULL);

# query 1
SELECT time, c1 FROM t1 WHERE NOT (c1 != 0);

# query 2
SELECT time, c1 FROM t1 WHERE NOT (c1 == 0);

Expected Behavior

Query 1 and Query 2 should return opposite results.

Actual behaviour

Both Query 1 and Query 2 can retrieve all the data.

Environment

  • OS:Ubuntu Server 22.04 LTS 64bit
  • TDengine Version:3.3.3.0

Additional Context

Hello, TDengine team. I'd like to confirm with you whether this is a logical bug?

@LingweiKuang LingweiKuang added the bug Something isn't working label Oct 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant