[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-19 Thread Danny Chen (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17019165#comment-17019165
 ] 

Danny Chen commented on CALCITE-3741:
-

Yes, the commit does not solve your problem, just a reference of how to fix 
your problem.

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png, 
> image-2020-01-17-09-40-47-906.png, image-2020-01-17-10-43-28-765.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-19 Thread james601232 (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17018879#comment-17018879
 ] 

james601232 commented on CALCITE-3741:
--

Dear [~danny0405]

       I check this PR 
[https://github.com/apache/calcite/commit/fe0a2fe7dde4a4a342cfc50f2f9da983cc60c479]
 and merge the changes. Unfortunately. the error still exists.

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png, 
> image-2020-01-17-09-40-47-906.png, image-2020-01-17-10-43-28-765.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread Danny Chen (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17017763#comment-17017763
 ] 

Danny Chen commented on CALCITE-3741:
-

Take this PR 
https://github.com/apache/calcite/commit/fe0a2fe7dde4a4a342cfc50f2f9da983cc60c479
 for a reference to see how to fix the sort.

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png, 
> image-2020-01-17-09-40-47-906.png, image-2020-01-17-10-43-28-765.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread james601232 (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17017679#comment-17017679
 ] 

james601232 commented on CALCITE-3741:
--

Dear [~danny0405]

 yes. ur right. could you give  me a temporary soulation fixed the order by 
issue not upgrade calcite version. for us upgrade calcite is a very large 
project. 

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png, 
> image-2020-01-17-09-40-47-906.png, image-2020-01-17-10-43-28-765.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread Danny Chen (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17017676#comment-17017676
 ] 

Danny Chen commented on CALCITE-3741:
-

I kind of know what happens, it is not the SqlParser, but the RelToSqlConverter 
that outputs the error SQL, can you try the latest code branch instead of 
1.17.0 ? We made some promotion for Jdbc sort unparse recently.

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png, 
> image-2020-01-17-09-40-47-906.png, image-2020-01-17-10-43-28-765.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread james601232 (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17017668#comment-17017668
 ] 

james601232 commented on CALCITE-3741:
--

Dear [~icshuo] 

        type sql is "select * from products {color:#ff}order by 
score{color}". but debug pic show two order by score words in 
{color:#de350b}node{color} and {color:#de350b}orderBy{color} struct. 

why node and orderBy have more than one order by score word. do it normally?

!image-2020-01-17-10-43-28-765.png!

 

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png, 
> image-2020-01-17-09-40-47-906.png, image-2020-01-17-10-43-28-765.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread Shuo Cheng (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17017651#comment-17017651
 ] 

Shuo Cheng commented on CALCITE-3741:
-

Hi, James, it would be more clear if you can just paste the original *test 
case* rather than the debugging pics.

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png, 
> image-2020-01-17-09-40-47-906.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread james601232 (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17017638#comment-17017638
 ] 

james601232 commented on CALCITE-3741:
--

Dear [~amaliujia]

        we  have a open project quicksql. it's use jdbc:calcite method query 
mongodb. type sql "select * from products order by score". calcite analysis and 
optimistc the sql found more than one “order by  score” key word in sql.  eg. 
“select * from products {color:#FF}order by score  order by score{color}” 
{color:#172b4d}. I tried debug codes and found SqlValidatorImpl class deal 
order by logic.  but i don't known how to cope it. hopeful getting help. thank 
u so much {color}

{color:#172b4d}!image-2020-01-17-09-40-47-906.png!{color}

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png, 
> image-2020-01-17-09-40-47-906.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread james601232 (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17017630#comment-17017630
 ] 

james601232 commented on CALCITE-3741:
--

Dear [~amaliujia] 

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread james601232 (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17017631#comment-17017631
 ] 

james601232 commented on CALCITE-3741:
--

Dear [~amaliujia]

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread Rui Wang (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17017365#comment-17017365
 ] 

Rui Wang commented on CALCITE-3741:
---

[~james601232] it could be very helpful if you share your test case.

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread Danny Chen (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17016719#comment-17016719
 ] 

Danny Chen commented on CALCITE-3741:
-

How did you test that ? I use the "select * from products order by score" in 
SqlParserTest and the SqlOrderBy#unparse works correctly.

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread james601232 (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17016699#comment-17016699
 ] 

james601232 commented on CALCITE-3741:
--

Dear [~danny0405]

        my sql is “select * from products order by score”.  after calcite 
analsys found duplicate order by in sql 

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread james601232 (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17016698#comment-17016698
 ] 

james601232 commented on CALCITE-3741:
--

Dear [~danny0405]   

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (CALCITE-3741) duplicate ‘ordre by‘ key word generate in select

2020-01-16 Thread Danny Chen (Jira)


[ 
https://issues.apache.org/jira/browse/CALCITE-3741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17016659#comment-17016659
 ] 

Danny Chen commented on CALCITE-3741:
-

Why you write multiple "order by"s in your query, i tried MySQL 5.6 and 
PostgreSQL 11g, they all fails with such syntax.

> duplicate ‘ordre by‘ key word generate in select
> 
>
> Key: CALCITE-3741
> URL: https://issues.apache.org/jira/browse/CALCITE-3741
> Project: Calcite
>  Issue Type: Bug
>  Components: mongodb-adapter
>Affects Versions: 1.17.0
>Reporter: james601232
>Priority: Major
> Attachments: image-2020-01-16-14-28-57-662.png
>
>
> Hi
>    I encoutner a problem use calcite query mongodb.  my select sql is "select 
> * from products order by score". unfortunatly.  calcite analysis sql concat 
> redundant 'order by score'  in sql.
> debug screenshot as following:
> !image-2020-01-16-14-28-57-662.png!
> could you help me what wrong happen. 
> Tks 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)