Update OracleRead.scala

fix a bug  about (ORA-00933: SQL command not properly ended)
This commit is contained in:
or 2019-08-06 17:18:47 +08:00 committed by GitHub
parent b855031fd8
commit 2e36dd9565
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -57,7 +57,7 @@ class OracleRead extends ConfigurableStop{
override def perform(in: JobInputStream, out: JobOutputStream, pec: JobContext): Unit = {
val spark = pec.get[SparkSession]()
val dbtable = "( " + sql + ") AS Temp"
val dbtable = "( " + sql + ")temp"
val jdbcDF = spark.read.format("jdbc")
.option("url", url)
.option("driver", "oracle.jdbc.OracleDriver")