huaxingao commented on a change in pull request #34673: URL: https://github.com/apache/spark/pull/34673#discussion_r758026935
########## File path: sql/core/src/main/scala/org/apache/spark/sql/jdbc/PostgresDialect.scala ########## @@ -164,4 +172,78 @@ private object PostgresDialect extends JdbcDialect { s"TABLESAMPLE BERNOULLI" + s" (${(sample.upperBound - sample.lowerBound) * 100}) REPEATABLE (${sample.seed})" } + + // CREATE INDEX syntax + // https://www.postgresql.org/docs/14/sql-createindex.html + override def createIndex( + indexName: String, + tableName: String, + columns: Array[NamedReference], + columnsProperties: util.Map[NamedReference, util.Map[String, String]], + properties: util.Map[String, String]): String = { Review comment: The implementation is similar to `MySQL`. We probably want to move this to `JdbcUtils` too for code reuse. -- 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: reviews-unsubscr...@spark.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org