Skip to content

Conversation

@sollhui
Copy link
Contributor

@sollhui sollhui commented Nov 3, 2025

What problem does this PR solve?

Fix wrong result when escape same as enclose, introduced by #50101

data:

50,"{""a"": 1}"
60,"{""a"": 2}"

query

select * from local( "backend_id" = "1760087225568", "file_path" = "test.csv", "format" = "csv", "column_separator" = ",", "enclose" = "\"", "escape" = "\""

expectation:

+------+------------+
| k1   | k2         |
+------+------------+
|   50 | {"a": 1} |
|   60 | {"a": 2} |
+------+------------+

real:

+------+------------------------+
| k1   | k2                     |
+------+------------------------+
|   50 | {"a": 1}
60,{"a": 2}

 |
+------+------------------------+

Release note

None

Check List (For Author)

  • Test

    • Regression test
    • Unit Test
    • Manual test (add detailed scripts or steps below)
    • No need to test or manual test. Explain why:
      • This is a refactor/code format and no logic has been changed.
      • Previous test can cover this change.
      • No code files have been changed.
      • Other reason
  • Behavior changed:

    • No.
    • Yes.
  • Does this need documentation?

    • No.
    • Yes.

Check List (For Reviewer who merge this PR)

  • Confirm the release note
  • Confirm test cases
  • Confirm document
  • Add branch pick label

@hello-stephen
Copy link
Contributor

Thank you for your contribution to Apache Doris.
Don't know what should be done next? See How to process your PR.

Please clearly describe your PR:

  1. What problem was fixed (it's best to include specific error reporting information). How it was fixed.
  2. Which behaviors were modified. What was the previous behavior, what is it now, why was it modified, and what possible impacts might there be.
  3. What features were added. Why was this function added?
  4. Which code was refactored and why was this part of the code refactored?
  5. Which functions were optimized and what is the difference before and after the optimization?

@sollhui
Copy link
Contributor Author

sollhui commented Nov 3, 2025

run buildall

Copy link
Contributor

@morningman morningman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@github-actions github-actions bot added the approved Indicates a PR has been approved by one committer. label Nov 3, 2025
@github-actions
Copy link
Contributor

github-actions bot commented Nov 3, 2025

PR approved by at least one committer and no changes requested.

@github-actions
Copy link
Contributor

github-actions bot commented Nov 3, 2025

PR approved by anyone and no changes requested.

@doris-robot
Copy link

ClickBench: Total hot run time: 28.9 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit 546bbcc3a9ca221b8ad4afe4b885afad5a897138, data reload: false

query1	0.06	0.05	0.05
query2	0.10	0.06	0.05
query3	0.26	0.10	0.09
query4	1.60	0.12	0.12
query5	0.28	0.27	0.27
query6	1.20	0.67	0.67
query7	0.04	0.02	0.02
query8	0.06	0.04	0.04
query9	0.65	0.56	0.56
query10	0.61	0.62	0.63
query11	0.20	0.13	0.13
query12	0.17	0.14	0.13
query13	0.63	0.61	0.63
query14	1.03	1.03	1.03
query15	0.90	0.86	0.90
query16	0.41	0.41	0.42
query17	1.15	1.14	1.23
query18	0.25	0.23	0.22
query19	2.04	1.97	1.90
query20	0.02	0.02	0.01
query21	15.36	0.20	0.14
query22	5.10	0.08	0.05
query23	15.62	0.32	0.12
query24	3.04	0.78	0.43
query25	0.08	0.06	0.07
query26	0.16	0.15	0.16
query27	0.08	0.06	0.07
query28	4.39	1.17	0.97
query29	12.63	4.50	3.71
query30	0.30	0.15	0.12
query31	2.84	0.67	0.40
query32	3.26	0.58	0.48
query33	3.09	3.16	3.18
query34	15.91	5.28	4.59
query35	4.60	4.62	4.63
query36	0.71	0.55	0.52
query37	0.11	0.07	0.07
query38	0.07	0.04	0.04
query39	0.04	0.03	0.04
query40	0.18	0.15	0.15
query41	0.09	0.03	0.04
query42	0.04	0.03	0.04
query43	0.05	0.04	0.04
Total cold run time: 99.41 s
Total hot run time: 28.9 s

@doris-robot
Copy link

BE UT Coverage Report

Increment line coverage 100.00% (1/1) 🎉

Increment coverage report
Complete coverage report

Category Coverage
Function Coverage 52.70% (18049/34249)
Line Coverage 37.99% (164078/431857)
Region Coverage 32.34% (125106/386896)
Branch Coverage 33.74% (54725/162188)

@hello-stephen
Copy link
Contributor

BE Regression && UT Coverage Report

Increment line coverage 100.00% (1/1) 🎉

Increment coverage report
Complete coverage report

Category Coverage
Function Coverage 71.45% (24055/33668)
Line Coverage 57.84% (250216/432602)
Region Coverage 52.90% (207609/392492)
Branch Coverage 54.64% (89227/163297)

@hello-stephen
Copy link
Contributor

BE Regression && UT Coverage Report

Increment line coverage 100.00% (1/1) 🎉

Increment coverage report
Complete coverage report

Category Coverage
Function Coverage 71.44% (24054/33668)
Line Coverage 57.84% (250230/432602)
Region Coverage 52.91% (207662/392492)
Branch Coverage 54.65% (89240/163297)

Copy link
Contributor

@liaoxin01 liaoxin01 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@morningman morningman merged commit 2facd9e into apache:master Nov 6, 2025
32 of 34 checks passed
github-actions bot pushed a commit that referenced this pull request Nov 6, 2025
### What problem does this PR solve?

Fix wrong result when escape same as enclose, introduced by
#50101

data:
```
50,"{""a"": 1}"
60,"{""a"": 2}"
```

query
```
select * from local( "backend_id" = "1760087225568", "file_path" = "test.csv", "format" = "csv", "column_separator" = ",", "enclose" = "\"", "escape" = "\""
```

expectation:
```
+------+------------+
| k1   | k2         |
+------+------------+
|   50 | {"a": 1} |
|   60 | {"a": 2} |
+------+------------+
```

real:
```
+------+------------------------+
| k1   | k2                     |
+------+------------------------+
|   50 | {"a": 1}
60,{"a": 2}

 |
+------+------------------------+
```
github-actions bot pushed a commit that referenced this pull request Nov 6, 2025
### What problem does this PR solve?

Fix wrong result when escape same as enclose, introduced by
#50101

data:
```
50,"{""a"": 1}"
60,"{""a"": 2}"
```

query
```
select * from local( "backend_id" = "1760087225568", "file_path" = "test.csv", "format" = "csv", "column_separator" = ",", "enclose" = "\"", "escape" = "\""
```

expectation:
```
+------+------------+
| k1   | k2         |
+------+------------+
|   50 | {"a": 1} |
|   60 | {"a": 2} |
+------+------------+
```

real:
```
+------+------------------------+
| k1   | k2                     |
+------+------------------------+
|   50 | {"a": 1}
60,{"a": 2}

 |
+------+------------------------+
```
morrySnow pushed a commit that referenced this pull request Nov 7, 2025
…close #57632 (#57762)

Cherry-picked from #57632

Co-authored-by: hui lai <laihui@selectdb.com>
yiguolei pushed a commit that referenced this pull request Nov 8, 2025
…close #57632 (#57763)

Cherry-picked from #57632

Co-authored-by: hui lai <laihui@selectdb.com>
wyxxxcat pushed a commit to wyxxxcat/doris that referenced this pull request Nov 18, 2025
…e#57632)

### What problem does this PR solve?

Fix wrong result when escape same as enclose, introduced by
apache#50101

data:
```
50,"{""a"": 1}"
60,"{""a"": 2}"
```

query
```
select * from local( "backend_id" = "1760087225568", "file_path" = "test.csv", "format" = "csv", "column_separator" = ",", "enclose" = "\"", "escape" = "\""
```

expectation:
```
+------+------------+
| k1   | k2         |
+------+------------+
|   50 | {"a": 1} |
|   60 | {"a": 2} |
+------+------------+
```

real:
```
+------+------------------------+
| k1   | k2                     |
+------+------------------------+
|   50 | {"a": 1}
60,{"a": 2}

 |
+------+------------------------+
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by one committer. dev/3.0.x dev/3.1.3-merged dev/4.0.2-merged reviewed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants