Hi
Try this:  SqlParser.create(expr).parseExpression();

Regards!

Aron Tao


kant kodali <[email protected]> 于2021年1月5日周二 上午9:34写道:

> Hi All,
>
> is there a way to parse only the where clause using calcite (any sample
> code)? meaning,  for example, assume the input is something like
>
> view1.col1 = value1 or view2.col2 = value2 and view3.col3 = value3
>
> I want to parse this expression and replace view1.col1 with a, view2.col2
> with b and view3.col3 = c such that the output should be
>
> a = value1 or b = value2 and c = value3.
>
> This is just an example but I can get more complex boolean expressions as
> input.
>
> Thanks!
>

Reply via email to