You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@flink.apache.org by sunny patel <su...@gmail.com> on 2016/09/27 12:09:59 UTC

Fwd: JDBC connection in Flink using Scala ( Last mail attachment fail so i am resending the file)

 ( Last email attachment fail so i am resending the file)

Hi Team,

I am wondering is that possible to add JDBC connection as a source or
target in Flink using Scala.
Could you kindly some one help on this? DB write/sink code is not working.
if you have any sample code please share it here.

*Thanks*
*Sunny*


[image: Inline image 1]

Re: JDBC connection in Flink using Scala ( Last mail attachment fail so i am resending the file)

Posted by Stephan Ewen <se...@apache.org>.
This is a pretty basic IDE setup issue you have, does not seem Flink
specific.

Make sure you set up your project properly. Following the quick starts is
the simplest way.

On Wed, Sep 28, 2016 at 2:44 PM, sunny patel <su...@gmail.com> wrote:

> HI Guys,
>
> I have JDBCOutput format based on the following method, it seem not
> working in flink scala version.
>
> JDBCOutputFormat
> .buildJDBCOutputFormat()
> .setDrivername("")
> .setDBUrl("")
> .setQuery("insert into mtable (Id, name, sector) values (?,?,?)")
> .finish() ;
>
> Do you have any similar example to write files from CSV to database?
>
> Cheers
> Sunny.
>
> On Wed, Sep 28, 2016 at 8:55 AM, Ufuk Celebi <uc...@apache.org> wrote:
>
>> Hey Sunny,
>>
>> I think it's fine to first post to a single mailing list. I'm would stick
>> to user@f.a.o for this question.
>>
>> You can have a look at the JDBCInputFormat and JDBCOutputFormat.
>>
>> – Ufuk
>>
>> On Tue, Sep 27, 2016 at 2:09 PM, sunny patel <su...@gmail.com>
>> wrote:
>>
>>>  ( Last email attachment fail so i am resending the file)
>>>
>>> Hi Team,
>>>
>>> I am wondering is that possible to add JDBC connection as a source or
>>> target in Flink using Scala.
>>> Could you kindly some one help on this? DB write/sink code is not
>>> working.
>>> if you have any sample code please share it here.
>>>
>>> *Thanks*
>>> *Sunny*
>>>
>>>
>>> [image: Inline image 1]
>>>
>>>
>>
>

Re: JDBC connection in Flink using Scala ( Last mail attachment fail so i am resending the file)

Posted by sunny patel <su...@gmail.com>.
HI Guys,

I have JDBCOutput format based on the following method, it seem not working
in flink scala version.

JDBCOutputFormat
.buildJDBCOutputFormat()
.setDrivername("")
.setDBUrl("")
.setQuery("insert into mtable (Id, name, sector) values (?,?,?)")
.finish() ;

Do you have any similar example to write files from CSV to database?

Cheers
Sunny.

On Wed, Sep 28, 2016 at 8:55 AM, Ufuk Celebi <uc...@apache.org> wrote:

> Hey Sunny,
>
> I think it's fine to first post to a single mailing list. I'm would stick
> to user@f.a.o for this question.
>
> You can have a look at the JDBCInputFormat and JDBCOutputFormat.
>
> – Ufuk
>
> On Tue, Sep 27, 2016 at 2:09 PM, sunny patel <su...@gmail.com> wrote:
>
>>  ( Last email attachment fail so i am resending the file)
>>
>> Hi Team,
>>
>> I am wondering is that possible to add JDBC connection as a source or
>> target in Flink using Scala.
>> Could you kindly some one help on this? DB write/sink code is not working.
>> if you have any sample code please share it here.
>>
>> *Thanks*
>> *Sunny*
>>
>>
>> [image: Inline image 1]
>>
>>
>

Re: JDBC connection in Flink using Scala ( Last mail attachment fail so i am resending the file)

Posted by Ufuk Celebi <uc...@apache.org>.
Hey Sunny,

I think it's fine to first post to a single mailing list. I'm would stick
to user@f.a.o for this question.

You can have a look at the JDBCInputFormat and JDBCOutputFormat.

– Ufuk

On Tue, Sep 27, 2016 at 2:09 PM, sunny patel <su...@gmail.com> wrote:

>  ( Last email attachment fail so i am resending the file)
>
> Hi Team,
>
> I am wondering is that possible to add JDBC connection as a source or
> target in Flink using Scala.
> Could you kindly some one help on this? DB write/sink code is not working.
> if you have any sample code please share it here.
>
> *Thanks*
> *Sunny*
>
>
> [image: Inline image 1]
>
>