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

Fixes ordering in SELECT INTO and printing of strings #7655

Merged
merged 6 commits into from
Mar 15, 2021

Conversation

GuptaManan100
Copy link
Member

@GuptaManan100 GuptaManan100 commented Mar 10, 2021

Description

The query select * from t1 into outfile '/tmp/foo.csv' fields escaped by '\\' terminated by '\n'; works on MySQL but was failing on Vitess. This is because we were parsing strings with escape characters but were not emitting it correctly, i.e. '\\' gets converted to '\'. This PR fixes this issue. Also, any ordering of TERMINATED BY, ENCLOSED BY and ESCAPED BY is permitted in MySQL. This is also addressed in this PR.

Checklist

  • Should this PR be backported? No
  • Tests were added or are not required Yes
  • Documentation was added or is not required Not Required

Impacted Areas in Vitess

Components that this PR will affect:

  • Query Serving

Signed-off-by: GuptaManan100 <manan@planetscale.com>
Signed-off-by: GuptaManan100 <manan@planetscale.com>
Signed-off-by: GuptaManan100 <manan@planetscale.com>
Signed-off-by: GuptaManan100 <manan@planetscale.com>
Signed-off-by: GuptaManan100 <manan@planetscale.com>
Signed-off-by: GuptaManan100 <manan@planetscale.com>
@systay systay merged commit de902e5 into vitessio:master Mar 15, 2021
@systay systay deleted the select-into branch March 15, 2021 13:15
@askdba askdba added this to the v10.0 milestone Mar 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants