spark-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sambit Tripathy (RBEI/EDS1)" <Sambit.Tripa...@in.bosch.com>
Subject What is "java.sql.SQLException: Unsupported type -101"?
Date Fri, 17 Jul 2015 21:01:06 GMT
Hi,

I was trying to get a oracle table using JDBC datasource

val jdbcDF = sqlContext.load("jdbc", Map( "url" -> "jdbc:oracle:thin:USER/PAWD@host.com:1517:sid",
"dbtable" -> "USER.TABLE","driver" -> "oracle.jdbc.OracleDriver"))

and got the error below

java.sql.SQLException: Unsupported type -101
        at org.apache.spark.sql.jdbc.JDBCRDD$.getCatalystType(JDBCRDD.scala:78)
        at org.apache.spark.sql.jdbc.JDBCRDD$.resolveTable(JDBCRDD.scala:112)
        at org.apache.spark.sql.jdbc.JDBCRelation.<init>(JDBCRelation.scala:133)
        at org.apache.spark.sql.jdbc.DefaultSource.createRelation(JDBCRelation.scala:121)
        at org.apache.spark.sql.sources.ResolvedDataSource$.apply(ddl.scala:219)
        at org.apache.spark.sql.SQLContext.load(SQLContext.scala:697)
        at $iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC.<init>(<console>:23)
        at $iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC.<init>(<console>:28)
        at $iwC$$iwC$$iwC$$iwC$$iwC$$iwC.<init>(<console>:30)
        at $iwC$$iwC$$iwC$$iwC$$iwC.<init>(<console>:32)
        at $iwC$$iwC$$iwC$$iwC.<init>(<console>:34)
        at $iwC$$iwC$$iwC.<init>(<console>:36)
        at $iwC$$iwC.<init>(<console>:38)
        at $iwC.<init>(<console>:40)
        at <init>(<console>:42)
        at .<init>(<console>:46)
        at .<clinit>(<console>)
        at .<init>(<console>:7)
        at .<clinit>(<console>)
        at $print(<console>)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:601)
        at org.apache.spark.repl.SparkIMain$ReadEvalPrint.call(SparkIMain.scala:1065)
        at org.apache.spark.repl.SparkIMain$Request.loadAndRun(SparkIMain.scala:1338)
        at org.apache.spark.repl.SparkIMain.loadAndRunReq$1(SparkIMain.scala:840)
        at org.apache.spark.repl.SparkIMain.interpret(SparkIMain.scala:871)
        at org.apache.spark.repl.SparkIMain.interpret(SparkIMain.scala:819)


Any idea what it could be?


Regards,
Sambit.


Mime
View raw message