You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "huaxingao (via GitHub)" <gi...@apache.org> on 2023/02/23 07:14:51 UTC
[GitHub] [spark] huaxingao commented on a diff in pull request #40134: [SPARK-42534][SQL] Fix DB2Dialect Limit clause
huaxingao commented on code in PR #40134:
URL: https://github.com/apache/spark/pull/40134#discussion_r1115304895
##########
connector/docker-integration-tests/src/test/scala/org/apache/spark/sql/jdbc/DB2IntegrationSuite.scala:
##########
@@ -217,4 +217,25 @@ class DB2IntegrationSuite extends DockerJDBCIntegrationSuite {
assert(actual.length === 2)
assert(actual.toSet === expectedResult)
}
+
+ test("SPARK-42534: DB2 Limit pushdown test") {
+ val actual = sqlContext.read
+ .format("jdbc")
+ .option("url", jdbcUrl)
+ .option("dbtable", "tbl")
+ .load()
+ .limit(2)
Review Comment:
Limit push down is only supported in V2 JDBC. I don't think this `limit(2)` will trigger the newly added `DB2Dialect.getLimitClause`. This test should be done in `v2/DB2IntegrationSuite`
--
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-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org