dongjoon-hyun commented on a change in pull request #34164:
URL: https://github.com/apache/spark/pull/34164#discussion_r721874979
##########
File path: sql/core/src/main/scala/org/apache/spark/sql/jdbc/JdbcDialects.scala
##########
@@ -287,6 +289,42 @@ abstract class JdbcDialect extends Serializable with
Logging{
s"COMMENT ON SCHEMA ${quoteIdentifier(schema)} IS NULL"
}
+ /**
+ * Creates an index.
+ *
+ * @param indexName the name of the index to be created
+ * @param indexType the IndexType of the index to be created
+ * @param tableName the table on which index to be created
+ * @param columns the columns on which index to be created
+ * @param columnsProperties the properties of the columns on which index to
be created
+ * @param properties the properties of the index to be created
+ */
+ def createIndex(
+ indexName: String,
+ indexType: String,
+ tableName: String,
+ columns: Array[NamedReference],
+ columnsProperties: Array[util.Map[NamedReference, util.Properties]],
+ properties: util.Properties): String = {
+ throw new UnsupportedOperationException("Create index is not supported")
+ }
+
+ /**
+ * Checks whether an index exists
+ *
+ * @param indexName the name of the index
+ * @param tableName the table on which index to be checked
+ * @param options JDBCOptions of the table
+ * @return true if the index exists, false otherwise
Review comment:
Could you elaborate a little more about `false otherwise`? I believe you
want to mention something like `not exists`, `unauthorized`, ....
##########
File path: sql/core/src/main/scala/org/apache/spark/sql/jdbc/JdbcDialects.scala
##########
@@ -287,6 +289,42 @@ abstract class JdbcDialect extends Serializable with
Logging{
s"COMMENT ON SCHEMA ${quoteIdentifier(schema)} IS NULL"
}
+ /**
+ * Creates an index.
+ *
+ * @param indexName the name of the index to be created
+ * @param indexType the IndexType of the index to be created
+ * @param tableName the table on which index to be created
+ * @param columns the columns on which index to be created
+ * @param columnsProperties the properties of the columns on which index to
be created
+ * @param properties the properties of the index to be created
+ */
+ def createIndex(
+ indexName: String,
+ indexType: String,
+ tableName: String,
+ columns: Array[NamedReference],
+ columnsProperties: Array[util.Map[NamedReference, util.Properties]],
+ properties: util.Properties): String = {
+ throw new UnsupportedOperationException("Create index is not supported")
+ }
+
+ /**
+ * Checks whether an index exists
+ *
+ * @param indexName the name of the index
+ * @param tableName the table on which index to be checked
+ * @param options JDBCOptions of the table
+ * @return true if the index exists, false otherwise
Review comment:
Could you elaborate a little more about `false otherwise`, please? I
believe you want to mention something like `not exists`, `unauthorized`, ....
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]