Page 1 of 1

After Job query in PX

Posted: Tue Nov 18, 2008 1:54 am
by vintipa
hi,

In a load job i read a file and then load it to oracle table using Oracle Enterprise stage. but in the same job i need to update one column of the table after the job finishes. this is same as after job query in server eddition. how can i acieve this in PX.

Posted: Tue Nov 18, 2008 2:14 am
by arvind_ds
Write a shell script to update the column of the table. Call this script through ExecSh after job utility.

HTH

Posted: Tue Nov 18, 2008 2:35 am
by singhald
Hello Vintipa,

In oracle enterprise stage we have options call Open Command and Close Command in stage propertise tab.

in your case you can use Closed Command options and can write the use defined sql query to update the table based on required condition.

Re: After Job query in PX

Posted: Tue Nov 18, 2008 3:18 am
by DEEPTI
Hi

Have a look at this post .... Might help u

viewtopic.php?t=90162&highlight=Sql+in+Oracle+stage

Thanks
Deepti

Posted: Tue Nov 18, 2008 3:40 am
by vintipa
Hi,

i am trying the close Command option now. i placed the foll query : update erec_pa9028 set ZZRLVLDT = '99991231' where ZZRLVLDT is null

but i get the following error : EREC_9028,2: Fatal Error: Invalid close command : update erec_pa9028 set ZZRLVLDT = '99991231' where ZZRLVLDT is null.

this runs fine in TOAD. may be there are some things to follow when writing a command in close command option!

please throw some light on this.

Posted: Tue Nov 18, 2008 5:06 am
by srinivas.g
Better to use DRS(Dynamic RDMS stage)

this stage contains before and after sql tab options as like as server oracle stage

Posted: Tue Nov 18, 2008 5:06 am
by srinivas.g
Better to use DRS(Dynamic RDMS stage)

this stage contains before and after sql tab options as like as server oracle stage

Posted: Tue Nov 18, 2008 5:26 am
by singhald
Hi vintipa ,

provide the correct databse schema name before the table name. and see weather you are running the oracle load in same schema or not

regards,

Posted: Tue Nov 18, 2008 6:43 am
by vintipa
hi :)

the DRS idea works for me.... thanks.
Now i'll try and achieve the same thing using Oracle Ent stage itself.
kindly let me know if anymore mistakes exist in the close command i used.