You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@datafusion.apache.org by "goldmedal (via GitHub)" <gi...@apache.org> on 2024/11/26 08:01:38 UTC

[I] Relation visitor fails to visit the `SHOW COLUMNS` statement in the latest commit of the main branch [datafusion-sqlparser-rs]

goldmedal opened a new issue, #1554:
URL: https://github.com/apache/datafusion-sqlparser-rs/issues/1554

   # Description
   This problem can be reproduced by adding a test case at
   https://github.com/apache/datafusion-sqlparser-rs/blob/525d1780e8f5c7ba6b7be327eaa788b6c8c47716/src/ast/visitor.rs#L736-L738
   
   Consider a case
   ```rust
               (
                   "SHOW COLUMNS FROM t1",
                   vec![
                       "PRE: STATEMENT: SHOW COLUMNS FROM t1",
                       "PRE: RELATION: t1",
                       "POST: RELATION: t1",
                       "POST: STATEMENT: SHOW COLUMNS FROM t1",
                   ],
               ),
   ```
   
   The test case is passed in the previous release tag `v0.52.0-rc3`. However, in the latest commit of the main branch 525d1780e8f5c7ba6b7be327eaa788b6c8c47716 , the test fails and the result is
   ```rust
        "PRE: STATEMENT: SHOW COLUMNS FROM t1",
        "POST: STATEMENT: SHOW COLUMNS FROM t1",
   ```
   
   It may cause the upstream project, DataFusion, to fail to execute the `SHOW COLUMNS FROM xxx` SQL.
   https://github.com/apache/datafusion/blob/18fc103a403ab0efe5245dd4352f3f3b93c2a4fe/datafusion/core/src/execution/session_state.rs#L540


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org


Re: [I] Relation visitor fails to visit the `SHOW COLUMNS` statement in the latest commit of the main branch [datafusion-sqlparser-rs]

Posted by "alamb (via GitHub)" <gi...@apache.org>.
alamb commented on issue #1554:
URL: https://github.com/apache/datafusion-sqlparser-rs/issues/1554#issuecomment-2500875547

   I suspect this was introduced by this PR from @yoavcloud
   
   - https://github.com/apache/datafusion-sqlparser-rs/pull/1501
   
   Any chance you can help us fix it @yoavcloud?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org


Re: [I] Relation visitor fails to visit the `SHOW COLUMNS` statement in the latest commit of the main branch [datafusion-sqlparser-rs]

Posted by "alamb (via GitHub)" <gi...@apache.org>.
alamb commented on issue #1554:
URL: https://github.com/apache/datafusion-sqlparser-rs/issues/1554#issuecomment-2504238994

   No problems -- clearly we don't have good test coverage for this either 🤔 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org


Re: [I] Relation visitor fails to visit the `SHOW COLUMNS` statement in the latest commit of the main branch [datafusion-sqlparser-rs]

Posted by "goldmedal (via GitHub)" <gi...@apache.org>.
goldmedal commented on issue #1554:
URL: https://github.com/apache/datafusion-sqlparser-rs/issues/1554#issuecomment-2499954022

   I think the reason is we changed the table name to `Option<ObjectName>` in https://github.com/apache/datafusion-sqlparser-rs/pull/1501 but the visitor can only recognize the `ObjectName`. 🤔 
   https://github.com/apache/datafusion-sqlparser-rs/blob/525d1780e8f5c7ba6b7be327eaa788b6c8c47716/src/ast/mod.rs#L7587-L7590


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org


Re: [I] Relation visitor fails to visit the `SHOW COLUMNS` statement in the latest commit of the main branch [datafusion-sqlparser-rs]

Posted by "yoavcloud (via GitHub)" <gi...@apache.org>.
yoavcloud commented on issue #1554:
URL: https://github.com/apache/datafusion-sqlparser-rs/issues/1554#issuecomment-2501961374

   Apologies for the regression here, I'm still learning my way around the project. Looks like @goldmedal has a PR already that addresses this issue. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org


Re: [I] Relation visitor fails to visit the `SHOW COLUMNS` statement in the latest commit of the main branch [datafusion-sqlparser-rs]

Posted by "alamb (via GitHub)" <gi...@apache.org>.
alamb commented on issue #1554:
URL: https://github.com/apache/datafusion-sqlparser-rs/issues/1554#issuecomment-2500869487

   Thank you for debugging this @goldmedal  🙏 
   
   I was wondering why that test was failing 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org


Re: [I] Relation visitor fails to visit the `SHOW COLUMNS` statement in the latest commit of the main branch [datafusion-sqlparser-rs]

Posted by "goldmedal (via GitHub)" <gi...@apache.org>.
goldmedal commented on issue #1554:
URL: https://github.com/apache/datafusion-sqlparser-rs/issues/1554#issuecomment-2500888432

   > Thank you for debugging this @goldmedal 🙏
   > 
   > I was wondering why that test was failing on
   > 
   > * [POC: Update to sqlparser with span (source text) location datafusion#13546](https://github.com/apache/datafusion/pull/13546)
   
   I tried to support to visit the option field by #1556 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org


Re: [I] Relation visitor fails to visit the `SHOW COLUMNS` statement in the latest commit of the main branch [datafusion-sqlparser-rs]

Posted by "alamb (via GitHub)" <gi...@apache.org>.
alamb closed issue #1554: Relation visitor fails to visit the `SHOW COLUMNS` statement in the latest commit of the main branch
URL: https://github.com/apache/datafusion-sqlparser-rs/issues/1554


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org