Re: Dynamically working out upperbound in JDBC connection to Oracle DB

2017-05-29 Thread Don Drake
Try passing maxID.toString, I think it wants the number as a string. On Mon, May 29, 2017 at 3:12 PM, Mich Talebzadeh wrote: > thanks Gents but no luck! > > scala> val s = HiveContext.read.format("jdbc").options( > | Map("url" -> _ORACLEserver, > | "dbtable" -> "(SELECT ID, CLUSTERED,

Re: Dynamically working out upperbound in JDBC connection to Oracle DB

2017-05-29 Thread Mich Talebzadeh
thanks Gents but no luck! scala> val s = HiveContext.read.format("jdbc").options( | Map("url" -> _ORACLEserver, | "dbtable" -> "(SELECT ID, CLUSTERED, SCATTERED, RANDOMISED, RANDOM_STRING, SMALL_VC, PADDING FROM scratchpad.dummy)", | "partitionColumn" -> "ID", | "lowerBound" ->

Re: Dynamically working out upperbound in JDBC connection to Oracle DB

2017-05-29 Thread ayan guha
You are using maxId as a string literal. Try removing the quotes around maxId On Tue, 30 May 2017 at 2:56 am, Jörn Franke wrote: > I think you need to remove the hyphen around maxid > > On 29. May 2017, at 18:11, Mich Talebzadeh > wrote: > > Hi, > > This JDBC connection works with Oracle table

Re: Dynamically working out upperbound in JDBC connection to Oracle DB

2017-05-29 Thread Jörn Franke
I think you need to remove the hyphen around maxid > On 29. May 2017, at 18:11, Mich Talebzadeh wrote: > > Hi, > > This JDBC connection works with Oracle table with primary key ID > > val s = HiveContext.read.format("jdbc").options( > Map("url" -> _ORACLEserver, > "dbtable" -> "(SELECT ID, CL

Dynamically working out upperbound in JDBC connection to Oracle DB

2017-05-29 Thread Mich Talebzadeh
Hi, This JDBC connection works with Oracle table with primary key ID val s = HiveContext.read.format("jdbc").options( Map("url" -> _ORACLEserver, "dbtable" -> "(SELECT ID, CLUSTERED, SCATTERED, RANDOMISED, RANDOM_STRING, SMALL_VC, PADDING FROM scratchpad.dummy)", "partitionColumn" -> "ID", *"low