-
Notifications
You must be signed in to change notification settings - Fork 3.8k
feat: add Tdengine parser and examples #4614
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
base: master
Are you sure you want to change the base?
Conversation
migrate from the parse module of TDengine. Signed-off-by: zhouyx <[email protected]>
You might want to check the ambiguity and parse tree result for some of your tests. Here are all the possible parse trees for select.sql.
There's ambiguity in columnReference because "ts" in line 3 of select.sql can be either a columnName or columnAlias because both can match NK_ID. The other ambiguity is with commonExpression/exprOrSubquery and commonExpression/booleanValueExpression. The ambiguity is detected in select.sql in line 5, with the expression after the "WHERE". The problem here is that you're trying to enter into an exprOrSubquery, but that references expression. This type of problem occurs in other grammars, but I haven't figured out a good way to split up an Antlr optimized left-recursive expression. You might want to include a readme.md so we can see where this is all coming from. |
Thank you for the review. I will try to resolve the ambiguity |
migrate from the parse module of TDengine.