omkar-shitole commented on code in PR #34227:
URL: https://github.com/apache/shardingsphere/pull/34227#discussion_r1926790618
##########
parser/sql/dialect/postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/PostgreSQLStatementVisitor.java:
##########
@@ -704,7 +704,7 @@ public ASTNode visitInsert(final InsertContext ctx) {
PostgreSQLInsertStatement result = (PostgreSQLInsertStatement)
visit(ctx.insertRest());
result.setTable((SimpleTableSegment) visit(ctx.insertTarget()));
if (null != ctx.optOnConflict()) {
-
result.setOnDuplicateKeyColumnsSegment((OnDuplicateKeyColumnsSegment)
visit(ctx.optOnConflict()));
+
result.setOnConflictKeyColumnsSegment((OnConflictKeyColumnsSegment)
visit(ctx.optOnConflict()));
Review Comment:
Please let me know what pattern should be followed in this case.
Postgres has `ON CONFLICT ` with the `WHERE` statement. Also, there is `DO
NOTHING` inside Postgres in Combination with `ON ONCLFICT`.
Mysql has `ON DUPLICATE` without a `WHERE` segment and apart from that there
is no as such difference between them.
--
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]