Page 1 of 1

Open command

Posted: Fri Nov 19, 2010 2:11 am
by jpraveen
Hi all

i want to update a table AZ_PMGProvXRef_Temp1 based on the below query

the Query is
Update AZ_PMGProvXRef_Temp1
Set
ProductID = 'CO'
where
ProductID = '3' or
productid = '0';

i want to do this in open command.
but open command cannot be used to commit(i had seen this in datastage developers guide), so how to commit the records in open command

can i put simply semi-colon ' ; ' or 'COMMIT;'
my database is SQL server-2005 and i am using ODBC stage and 2-node config file


Thanks in advance

Posted: Fri Nov 19, 2010 4:41 am
by ray.wurlod
Have you given any thought to what will happen when this stage runs on two or more nodes?

Posted: Fri Nov 19, 2010 4:52 am
by jpraveen
Hi ray

i think open command can be used when insert array is processed. and it cannot be used for COMMIT. and it will run only one time on conductor node.
but my requirement is to update the table before loading into the same table and my source is user- defined SQL ,
suggest me if any changes should be made while coding?

Thx