sadikovi commented on code in PR #39660: URL: https://github.com/apache/spark/pull/39660#discussion_r1083555135
########## sql/core/src/main/scala/org/apache/spark/sql/jdbc/JdbcDialects.scala: ########## @@ -544,6 +544,14 @@ abstract class JdbcDialect extends Serializable with Logging { if (limit > 0 ) s"LIMIT $limit" else "" } + /** + * MS SQL Server version of `getLimitClause`. + * This is only supported by SQL Server as it uses TOP (N) instead. + */ + def getTopExpression(limit: Integer): String = { Review Comment: What exactly is hacky in this API? As far as I can see, it just follows the existing JDBC code. If you are referring to an alternative implementation, then I am happy to consider it, otherwise please elaborate. -- 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