You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user-zh@flink.apache.org by 忝忝向仧 <15...@qq.com> on 2020/10/04 09:09:23 UTC

Flink的table-api不支持.

Hi,all:


Table api的sql查询里面join的时候不能写"."么?
这样写就会报错 如下
Exception in thread "main" org.apache.flink.table.api.SqlParserException: SQL parse failed. Encountered "." at line 1, column 36.
Was expecting one of:
&nbsp; &nbsp; <EOF&gt;&nbsp;
&nbsp; &nbsp; "EXCEPT" ...
&nbsp; &nbsp; "FETCH" ...
&nbsp; &nbsp; "FROM" ...
&nbsp; &nbsp; "INTERSECT" ...
&nbsp; &nbsp; "LIMIT" ...
&nbsp; &nbsp; "OFFSET" ...
&nbsp; &nbsp; "ORDER" ...
&nbsp; &nbsp; "MINUS" ...
&nbsp; &nbsp; "UNION" ...
&nbsp; &nbsp; "," ...



Table result = tEnv.sqlQuery("select *  from  OrderA join OrderB on OrderA.user=OrderB.user");

回复:Flink的table-api不支持.

Posted by 大森林 <ap...@foxmail.com>.
这是官方技术支持吗?
怎么搞得像个邮件形式的论坛?




------------------&nbsp;原始邮件&nbsp;------------------
发件人:                                                                                                                        "user-zh"                                                                                    <153488125@qq.com&gt;;
发送时间:&nbsp;2020年10月4日(星期天) 下午5:09
收件人:&nbsp;"user-zh"<user-zh@flink.apache.org&gt;;

主题:&nbsp;Flink的table-api不支持.



Hi,all:


Table api的sql查询里面join的时候不能写"."么?
这样写就会报错 如下
Exception in thread "main" org.apache.flink.table.api.SqlParserException: SQL parse failed. Encountered "." at line 1, column 36.
Was expecting one of:
&amp;nbsp; &amp;nbsp; <EOF&amp;gt;&amp;nbsp;
&amp;nbsp; &amp;nbsp; "EXCEPT" ...
&amp;nbsp; &amp;nbsp; "FETCH" ...
&amp;nbsp; &amp;nbsp; "FROM" ...
&amp;nbsp; &amp;nbsp; "INTERSECT" ...
&amp;nbsp; &amp;nbsp; "LIMIT" ...
&amp;nbsp; &amp;nbsp; "OFFSET" ...
&amp;nbsp; &amp;nbsp; "ORDER" ...
&amp;nbsp; &amp;nbsp; "MINUS" ...
&amp;nbsp; &amp;nbsp; "UNION" ...
&amp;nbsp; &amp;nbsp; "," ...



Table result = tEnv.sqlQuery("select *&nbsp; from&nbsp; OrderA join OrderB on OrderA.user=OrderB.user");

Re: Flink的table-api不支持.

Posted by Benchao Li <li...@apache.org>.
user是关键字,需要用`user`来处理一下~

Kyle Zhang <sh...@gmail.com> 于2020年10月9日周五 上午8:34写道:

> 试一试select *  from  OrderA orderA join OrderB orderB on
> orderA.user=orderB.user
>
> On Sun, Oct 4, 2020 at 5:09 PM 忝忝向仧 <15...@qq.com> wrote:
>
> > Hi,all:
> >
> >
> > Table api的sql查询里面join的时候不能写"."么?
> > 这样写就会报错 如下
> > Exception in thread "main" org.apache.flink.table.api.SqlParserException:
> > SQL parse failed. Encountered "." at line 1, column 36.
> > Was expecting one of:
> > &nbsp; &nbsp; <EOF&gt;&nbsp;
> > &nbsp; &nbsp; "EXCEPT" ...
> > &nbsp; &nbsp; "FETCH" ...
> > &nbsp; &nbsp; "FROM" ...
> > &nbsp; &nbsp; "INTERSECT" ...
> > &nbsp; &nbsp; "LIMIT" ...
> > &nbsp; &nbsp; "OFFSET" ...
> > &nbsp; &nbsp; "ORDER" ...
> > &nbsp; &nbsp; "MINUS" ...
> > &nbsp; &nbsp; "UNION" ...
> > &nbsp; &nbsp; "," ...
> >
> >
> >
> > Table result = tEnv.sqlQuery("select *  from  OrderA join OrderB on
> > OrderA.user=OrderB.user");
>


-- 

Best,
Benchao Li

Re: Flink的table-api不支持.

Posted by Kyle Zhang <sh...@gmail.com>.
试一试select *  from  OrderA orderA join OrderB orderB on
orderA.user=orderB.user

On Sun, Oct 4, 2020 at 5:09 PM 忝忝向仧 <15...@qq.com> wrote:

> Hi,all:
>
>
> Table api的sql查询里面join的时候不能写"."么?
> 这样写就会报错 如下
> Exception in thread "main" org.apache.flink.table.api.SqlParserException:
> SQL parse failed. Encountered "." at line 1, column 36.
> Was expecting one of:
> &nbsp; &nbsp; <EOF&gt;&nbsp;
> &nbsp; &nbsp; "EXCEPT" ...
> &nbsp; &nbsp; "FETCH" ...
> &nbsp; &nbsp; "FROM" ...
> &nbsp; &nbsp; "INTERSECT" ...
> &nbsp; &nbsp; "LIMIT" ...
> &nbsp; &nbsp; "OFFSET" ...
> &nbsp; &nbsp; "ORDER" ...
> &nbsp; &nbsp; "MINUS" ...
> &nbsp; &nbsp; "UNION" ...
> &nbsp; &nbsp; "," ...
>
>
>
> Table result = tEnv.sqlQuery("select *  from  OrderA join OrderB on
> OrderA.user=OrderB.user");