ediconss opened a new issue, #27957:
URL: https://github.com/apache/shardingsphere/issues/27957

   ## Bug Report
   
   when use PostgreSQL parse  "ALTER TABLE tbl RENAME COLUMN c1 to c2" , use 
PostgreSQLAlterTableStatement.getRenameColumnDefinitions is return null
   ### Which version of ShardingSphere did you use?
   
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   ShardingSphere-Parse
   ### Expected behavior
   PostgreSQLAlterTableStatement.getRenameColumnDefinitions return 
RenameColumnDefinitions
   ### Actual behavior
   return null
   ### Reason analyze (If you can)
   in PostgreSQLDDLStatementVisitor.visitAlterDefinitionClause methed not set 
   
   ```
       @Override
       public ASTNode visitAlterDefinitionClause(final 
AlterDefinitionClauseContext ctx) {
           CollectionValue<AlterDefinitionSegment> result = new 
CollectionValue<>();
           PostgreSQLStatementParser.AlterTableActionsContext 
alterTableActionsContext = ctx.alterTableActions();
           if (null != alterTableActionsContext) {
               
result.getValue().addAll(alterTableActionsContext.alterTableAction().stream().flatMap(each
 -> getAlterDefinitionSegments(each).stream()).collect(Collectors.toList()));
           }
           if (null != ctx.renameTableSpecification()) {
               result.getValue().add((RenameTableDefinitionSegment) 
visit(ctx.renameTableSpecification()));
           }
           return result;
       }
   ```
   ### Steps to reproduce the behavior, such as: SQL to execute, sharding rule 
configuration, when exception occur etc.
   
   ### Example codes for reproduce this issue (such as a github link).
   


-- 
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: 
[email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to