matrixorigin / matrixorigin/matrixone

[Bug]: order by result different from mysql

Open
#3,334 10 comments 0 reactions 1 assignee Assigned to @aunjgr View on GitHub
area/compatibility bvt kind/bug priority/p0
Dominant language
Go
Stars
1.9k
Forks
311
Avg merge
1d 3h
Merged PRs (30d)
768

Description

### Is there an existing issue for the same bug?

- [X] I have checked the existing issues.

### Environment

```markdown
- Version or commit-id (e.g. v0.1.0 or 8b23a93): 6dedae20180c9e7ad4159ef0c7ad0f8e8c358dee
- Hardware parameters: MAC M1 ARM 16GB
- OS type: OSX
- Others:
```

### Actual Behavior

CREATE TABLE t1 (st varchar(255) NOT NULL, u int(11) NOT NULL);
INSERT INTO t1 VALUES ('a',1),('A',1),('aa',1),('AA',1),('a',1),('aaa',0),('BBB',0);
select if(u=1,st,st) s from t1 order by s;

[SQL STATEMENT]: select if(u=1,st,st) s from t1 order by s;
[EXPECT RESULT]:
s
a
A
a
aa
AA
aaa
BBB
[ACTUAL RESULT]:
s
A
AA
BBB
a
a
aa
aaa

### Expected Behavior

_No response_

### Steps to Reproduce

_No response_

### Additional information

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.