sqoop-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kristopher Kane <kkane.l...@gmail.com>
Subject Re: oozie sqoop write query result to a file
Date Wed, 25 Nov 2015 05:45:40 GMT
Sedat,

You could run your COUNT query in an Oozie shell or Java action and capture
the output to use in a decision tree inside Oozie. You would access this
count value from a key based on the echo output from Oozie shell or a key
from a Java properties class. Both are documented well in Oozie.

Kris

On Wed, Nov 4, 2015 at 3:07 PM, Sedat Kestepe <skestepe@gmail.com> wrote:

> Hi,
>
> I have an existing oozie job that makes a query on an Oracle table and
> overwrite the result on hive tables.
> Now I need to decide overwriting the hive table fi the query returns any
> data.
>
> My plan was to run a "select count(*) from..." style record count check.
> Then write the output to a file, read the file in second action. There I
> would put a decision action whether or not to run the main query and
> overwrite hive table.
>
> On the examples and documentation on web, target was to write the result
> on a hive table. Actually this is the purpose of sqoop but I couldn't find
> any thing related to writing the result in a file.
>
> --
> Sedat Kestepe
>

Mime
View raw message