Is there any limit for query size in OCI stage?

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

Post Reply
dskid
Participant
Posts: 13
Joined: Mon Jun 19, 2006 12:23 am
Location: uk

Is there any limit for query size in OCI stage?

Post by dskid »

Hello guys,
I am facing some problem related to Oracle stage. In my oracle TARGET stage i am passing a query which i am Selecting and Updating on the same table and that query is too big like it has 1219 characters.
the problem here is if my query is more than 1220 characters its not executing the query and giving fatal that "The provided update statement did not prepare correctly" and update set x.column name = ( se?trim(. and its triming the last part of the query and its not sending the entire query but giving fatal error.
In my job design i am using row generator as source so that i will trigger this query from datastage.
Edwink
Participant
Posts: 47
Joined: Sat Aug 19, 2006 4:57 am
Location: Chennai

Post by Edwink »

can u able to excute the same query through SQL plus?
dskid
Participant
Posts: 13
Joined: Mon Jun 19, 2006 12:23 am
Location: uk

Post by dskid »

i was able to execute that from SQL plus. but when i try to do that from oracle stage its aborting and i am tryng it from ODBC stage.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Looks like there might be such a limit. It's not documented in the manuals. Ask your support provider, who can ask IBM engineering.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
dskid
Participant
Posts: 13
Joined: Mon Jun 19, 2006 12:23 am
Location: uk

Post by dskid »

It seems there is a limit for No.of characters and its around 1220 for oracle and 2000 for teradata. i am able to run the same through ODBC stage without any issue.
thanks
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Do you know if this limitation is specific to the Oracle Enterprise stage? It must be as I have a couple of my peoples who loves the long user-defined sqls and I haven't run into this issue on the Server side.

I just pulled one example at random and pasted it into Word for some stats:

Characters: 4893
Characters (with spaces): 15705

:?
-craig

"You can never have too many knives" -- Logan Nine Fingers
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Are there any line terminator characters in your query?

You have marked the topic as resolved. Please post the resolution.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Who, me? Tons.

The resolution seems to be to use shorter queries. That or the ODBC stage. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Not you. You're not the OP, so could not have marked the post as resolved.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
dskid
Participant
Posts: 13
Joined: Mon Jun 19, 2006 12:23 am
Location: uk

Post by dskid »

I resolved this issue by using ODBC stage. when i executed the same query using Oracle enterprise stage its triming the last characters in the query which are more than 1220 and throwing a fatal error that SQL query not prepared properly, when i used the same after removing some fileds(only to reduce the lenght of query) which is less than 1220 then its working fine.
Post Reply