You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "leookok (Jira)" <ji...@apache.org> on 2019/09/14 06:38:00 UTC

[jira] [Created] (SPARK-29085) spark jdbc query to oracle "__SPARK_GEN_JDBC_SUBQUERY_NAME_" "__" not suport by ORACLE

leookok created SPARK-29085:
-------------------------------

             Summary: spark jdbc query to oracle "__SPARK_GEN_JDBC_SUBQUERY_NAME_" "__" not suport by ORACLE
                 Key: SPARK-29085
                 URL: https://issues.apache.org/jira/browse/SPARK-29085
             Project: Spark
          Issue Type: Bug
          Components: SQL
    Affects Versions: 2.4.3
            Reporter: leookok


when i use spark sql that jdbc connect to query data from oracle,

 
{code:java}
// code placeholder
Dataset<Row> jdbcDF = sqlContext.read()
        .format("jdbc")
        .option("url", "jdbc:oracle:thin:@192.168.2.3/orcltest11g")
        .option("query", "select * from tdb.user u")
        .option("user", "tdb")
        .option("password", "tdb")
        .load();
{code}
will throw error exception

 

 
{code:java}
// code placeholder
Exception in thread "main" java.sql.SQLSyntaxErrorException: ORA-00911: invalid character
{code}
 

in debug model 

 
{code:java}
// code placeholder
(select * from tdb.user u) __SPARK_GEN_JDBC_SUBQUERY_NAME_0
{code}
copy this sql to oracle client shell

will return same error <{color:#FF0000}__{color}SPARK_GEN_JDBC_SUBQUERY_NAME_0>

 

 

 

 



--
This message was sent by Atlassian Jira
(v8.3.2#803003)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org