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

keep "<" and ">" special char in columns names when properly quoted #89

Closed
gtanzi opened this issue Oct 30, 2021 · 3 comments
Closed

keep "<" and ">" special char in columns names when properly quoted #89

gtanzi opened this issue Oct 30, 2021 · 3 comments

Comments

@gtanzi
Copy link

gtanzi commented Oct 30, 2021

First of all, wanna compliment you for this helpful tool!

I came into a (possibly?) minor bug when trying to parse an hql file containing column names with special characters "<" or ">" properly quoted like:
something<2% float
I found out this is due to "parser.pre_process_line" that insert spaces around "<" and ">" if "(" not in line.
Possible solution is not to insert spaces if "<" ">" are inbetween quotes.

@xnuinside
Copy link
Owner

xnuinside commented Oct 30, 2021

@gtanzi , hi! Thanks for warm words and reporting the issue. I will be back from vacation on 8 of November and will take a look :) thank you!

@xnuinside
Copy link
Owner

@gtanzi about spaces - I added them because of some issues with parsing HQL structures like this - ARRAYstructcolx:string,coly:string. I will work on more normal workaround and will try to remove it.

@xnuinside
Copy link
Owner

xnuinside commented Nov 20, 2021

@gtanzi sorry that it took so much time - worked on another issues, I fixed this problem in 0.22.5 (already released - https://pypi.org/project/simple-ddl-parser/). https://github.com/xnuinside/simple-ddl-parser/blob/main/tests/test_hql_output_mode.py#L1888 - test added. Feel free to open the new issue if needed something. Thank you!

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

2 participants