Page 1 of 1

Deleting Data with Datastage

Posted: Wed Dec 03, 2008 4:30 am
by jassu
Hi,
I am trying to delete data from the table using DB2_UDB_Enterprise stage.I am using the Delete option in this stage. But when I run the job it is giving me the following error.
"Unable to convert the adapter spec ostrstream object with a value of `' to ustring."
I am not using the USTRING type any where in the Job and I am passing a value in the delete statement like "DELETE FROM <TABLE_NAME> WHERE <COLUMN_NAME>=VALUE".
Please help me in finding a solution for this problem.

Re: Deleting Data with Datastage

Posted: Sat Jul 04, 2009 9:30 am
by mithun.mg
Hi Jassu,

Please check on what keys the table you are trying to delete is partitoned.

If suppose the the table is partiotned on colA and ColB ,Then try using the below query in your DB2 Enterprise stage:

"DELETE FROM <TABLE_NAME> WHERE <COLUMN_NAME>=VALUE OR COLA=-1 OR COLB=-1".

If the tables is partitoned on any date column then use col='01-01-0001'

Posted: Sun Jul 05, 2009 5:20 pm
by ray.wurlod
Import the target table definition. Are there any NChar or NVarChar columns defined in the imported table definitions? If so, these are the ustrings about which the exporter is complaining.