You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2022/10/09 04:53:43 UTC

[GitHub] [shardingsphere] runqi-zhao opened a new issue, #18496: [OSPP 2022 ]Solve unsupported PostgreSQL about SQL dialect for ShardingSphere Parser

runqi-zhao opened a new issue, #18496:
URL: https://github.com/apache/shardingsphere/issues/18496

   This issue is created to better track my PRs for OSPP 2022, you can view more about my project [here](https://summer-ospp.ac.cn/#/org/prodetail/22ee10095)
   
   ## Background
   
   ShardingSphere Parser Engine helps users parse SQL statements into AST and generate corresponding SQL Statement objects from it.
   
   #### How is a SQL parsed?
   
   ```
   SQL definition file`
   ->(Parse to)
   `AST`
   ->(Visit it)
   `SQLStatment
   ```
   
   ## Process
   
   1. Compare SQL definitions in [Oficial SQL Doc](https://www.postgresql.org/docs/14/sql-commands.html) and [ShardingSphere SQL Doc](https://github.com/apache/shardingsphere/tree/master/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/antlr4/imports/postgresql)
   2. If there is any difference in ShardingSphere SQL Doc, please correct them referring to Official SQL Doc
   3. refer to [PostgreSql source code](https://github.com/postgres/postgres/blob/master/src/backend/parser/gram.y)
   4. Run mvn install the `current_file_module`
   5. Check whether there are any exceptions. If indeed, please fix them. (Especially xxxVisitor.class)
   6. Add new corresponding SQL case in [SQL Cases](https://github.com/apache/shardingsphere/tree/master/shardingsphere-test/shardingsphere-parser-test/src/main/resources/sql/supported) and expected parsed result in[ Expected Statment XML](https://github.com/apache/shardingsphere/tree/master/shardingsphere-test/shardingsphere-parser-test/src/main/resources/case)
   7. Run [SQLParserParameterizedTest](https://github.com/apache/shardingsphere/blob/master/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/engine/SQLParserParameterizedTest.java) to make sure no exceptions.
   ## Tasks
   - [x] LISTEN [doc](https://www.postgresql.org/docs/current/sql-listen.html)
   - [x] LOCK [doc](https://www.postgresql.org/docs/current/sql-lock.html)
   - [x] MOVE [doc](https://www.postgresql.org/docs/current/sql-move.html)
   - [x] NOTIFY [doc](https://www.postgresql.org/docs/current/sql-notify.html)
   - [x] PREPARE TRANSACTION [doc](https://www.postgresql.org/docs/current/sql-prepare-transaction.html)
   - [x] REASSIGN OWNED [doc](https://www.postgresql.org/docs/current/sql-reassign-owned.html)
   - [x] REFRESH MATERIALIZED VIEW [doc](https://www.postgresql.org/docs/current/sql-refreshmaterializedview.html)
   - [x] REINDEX [doc](https://www.postgresql.org/docs/current/sql-reindex.html)
   - [x] RESET [doc](https://www.postgresql.org/docs/current/sql-reset.html)
   - [x] SECURITY LABEL [doc](https://www.postgresql.org/docs/current/sql-security-label.html)
   - [x] TRUNCATE [doc](https://www.postgresql.org/docs/current/sql-truncate.html)
   - [x] UNLISTEN [doc](https://www.postgresql.org/docs/current/sql-unlisten.html)
   
   This issue is a ref to [#14104](https://github.com/apache/shardingsphere/issues/14104)


-- 
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: notifications-unsubscribe@shardingsphere.apache.org.apache.org

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


[GitHub] [shardingsphere] strongduanmu commented on issue #18496: [OSPP 2022 ]Solve unsupported PostgreSQL about SQL dialect for ShardingSphere Parser

Posted by GitBox <gi...@apache.org>.
strongduanmu commented on issue #18496:
URL: https://github.com/apache/shardingsphere/issues/18496#issuecomment-1272455354

   This issue has not been finished, so I will reopen it.


-- 
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: notifications-unsubscribe@shardingsphere.apache.org

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


[GitHub] [shardingsphere] github-actions[bot] closed issue #18496: [OSPP 2022 ]Solve unsupported PostgreSQL about SQL dialect for ShardingSphere Parser

Posted by GitBox <gi...@apache.org>.
github-actions[bot] closed issue #18496: [OSPP 2022 ]Solve unsupported PostgreSQL about SQL dialect for ShardingSphere Parser
URL: https://github.com/apache/shardingsphere/issues/18496


-- 
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: notifications-unsubscribe@shardingsphere.apache.org

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


[GitHub] [shardingsphere] github-actions[bot] commented on issue #18496: [OSPP 2022 ]Solve unsupported PostgreSQL about SQL dialect for ShardingSphere Parser

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on issue #18496:
URL: https://github.com/apache/shardingsphere/issues/18496#issuecomment-1272349585

   Hello , this issue has not received a reply for several days.
   This issue is supposed to be closed.


-- 
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: notifications-unsubscribe@shardingsphere.apache.org

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


[GitHub] [shardingsphere] runqi-zhao closed issue #18496: [OSPP 2022 ]Solve unsupported PostgreSQL about SQL dialect for ShardingSphere Parser

Posted by "runqi-zhao (via GitHub)" <gi...@apache.org>.
runqi-zhao closed issue #18496: [OSPP 2022 ]Solve unsupported PostgreSQL about SQL dialect for ShardingSphere Parser
URL: https://github.com/apache/shardingsphere/issues/18496


-- 
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: notifications-unsubscribe@shardingsphere.apache.org

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