beliefer commented on code in PR #39062:
URL: https://github.com/apache/spark/pull/39062#discussion_r1057516841


##########
sql/core/src/main/scala/org/apache/spark/sql/jdbc/JdbcDialects.scala:
##########
@@ -135,6 +135,18 @@ abstract class JdbcDialect extends Serializable with 
Logging {
     s""""$colName""""
   }
 
+  /**
+   * Get the SQL query that should be used to create a table. Dialects can
+   * override this method to return a query that works best in a particular 
database.
+   * @param tableName The name of the table.
+   * @param strSchema The string of the schema.
+   * @param createTableOptions The string of the options that to allow certain 
options to append
+   *             when create a new table, which can be table_options or 
partition_options.
+   */
+  def createTable(tableName: String, strSchema: String, createTableOptions: 
String): String = {

Review Comment:
   It seems strSchema prevent supporting different databases if schema is 
different.
   Could you think about more general scenarios ?
   I guess we should add another API to customize the schema str by dialect.



-- 
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]

Reply via email to