Seok-Joon,Yun created ZEPPELIN-3376:
---------------------------------------

             Summary: Can't apply jdbc option method
                 Key: ZEPPELIN-3376
                 URL: https://issues.apache.org/jira/browse/ZEPPELIN-3376
             Project: Zeppelin
          Issue Type: Bug
          Components: Interpreters
         Environment: zeppelin lastest version
            Reporter: Seok-Joon,Yun


I used spark.read.format("jdbc"). I need using unicode option. So I use this 
way.

 

val df = spark.read.format("jdbc").option("url", 
"jdbc:mysql:/...3306/dbname").option("dbtable", query).option("user", 
"username").option("password", "password").option("useUnicode", 
"true").option("characterEncoding", "utf8").load()

 

But It is not executed, because query contains Korean words.

So I change code this way.

 

val df = spark.read.format("jdbc").option("url", 
"jdbc:mysql:/...3306/dbname?useUnicode=true&characterEncoding=utf8").option("dbtable",
 query).option("user", "username").option("password", "password").load()

 

It worked well.

 

I can not be sure this is a zeppelin problem. It maybe problem of jdbc driver 
or spark library.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to