Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.
Moderators: chulett , rschirm , roy
mohandl
Participant
Posts: 43 Joined: Tue Dec 26, 2006 7:01 am
Location: pune
Post
by mohandl » Sun Jul 27, 2008 11:21 pm
Hi all,
i have one user defind query like below
delete * from <<table_name>>;
Insert into <<table_name>>
(
--
--
---
)
select * from <<Table_name1>>
The above user defined query i have to place in single stage in Parallel Job like (serevr jobs ODBC stage)
I am trying to place in DRS or Entrprise ODBC ,But i am not able place at a time, Is there any way to palce whole SQL query.
Regards,
Mohan
MOHAN
keshav0307
Premium Member
Posts: 783 Joined: Mon Jan 16, 2006 10:17 pm
Location: Sydney, Australia
Post
by keshav0307 » Sun Jul 27, 2008 11:35 pm
what is the database.
oracle, you can try for Stored procedure stage.
mohandl
Participant
Posts: 43 Joined: Tue Dec 26, 2006 7:01 am
Location: pune
Post
by mohandl » Sun Jul 27, 2008 11:53 pm
Hi Keshav ,
My database is SQL Server.
MOHAN
keshav0307
Premium Member
Posts: 783 Joined: Mon Jan 16, 2006 10:17 pm
Location: Sydney, Australia
Post
by keshav0307 » Mon Jul 28, 2008 2:38 am
so this query will run only once?
OddJob
Participant
Posts: 163 Joined: Tue Feb 28, 2006 5:00 am
Location: Sheffield, UK
Post
by OddJob » Mon Jul 28, 2008 4:48 am
In the past I have issued this kind of call in the 'Open' command string or in the 'Before' sql section.
For the actual data extract part I've included a 'SELECT COUNT(*)' for the table being populated to allow further checks and reporting on the actual number of records inserted.