Spark JDBC Oracle陷入了一项任务

发布于 2025-02-13 17:21:44 字数 751 浏览 0 评论 0原文

我正在Oracle运行下面的查询:

df = spark.read \
.format("jdbc") \
.option("url", "{}".format(db_url)) \
.option("dbtable","({})".format(query)) \
.option("user","{}".format(db_username)) \
.option("numPartitions", 1000) \
.option("partitionColumn", "CD_CONVENIO") \
.option("lowerBound", int(ParameterBound['MIN'])) \
.option("upperBound", int(ParameterBound['MAX'])) \
.option("password","{}".format(db_password)) \
.option("customSchema", schema) \
.option("driver", "oracle.jdbc.driver.OracleDriver") \
.load()

返回了大约19,000行。

但是该过程很长一段时间都陷入了一项任务。

I'm running the query below in oracle:

df = spark.read \
.format("jdbc") \
.option("url", "{}".format(db_url)) \
.option("dbtable","({})".format(query)) \
.option("user","{}".format(db_username)) \
.option("numPartitions", 1000) \
.option("partitionColumn", "CD_CONVENIO") \
.option("lowerBound", int(ParameterBound['MIN'])) \
.option("upperBound", int(ParameterBound['MAX'])) \
.option("password","{}".format(db_password)) \
.option("customSchema", schema) \
.option("driver", "oracle.jdbc.driver.OracleDriver") \
.load()

Approximately 199 thousand rows returned.

enter image description here

But the process gets stuck in one task for a long time.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文