By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,225 Members | 1,051 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,225 IT Pros & Developers. It's quick & easy.

error of dynamic SQL

P: n/a
I created a procedure with dynamic SQL. Building is successful.But when
I run it, it shows me the following error:

A database manager error occurred.[IBM][CLI Driver][DB2/NT] SQL0104N
An unexpected token "pd.proposal_id , pd.item_id , psd.year_id" was
found following "( select". Expected tokens may include:
"<space>". SQLSTATE=42601

In procedure, the part is
' select pd.proposal_id '||
' ,pd.item_id '||
' ,y.year_id '||

What is wrong? There do have spaces following 'select'.

Thanks for help!

Nov 12 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
li******@yahoo.ca wrote:
I created a procedure with dynamic SQL. Building is successful.But when
I run it, it shows me the following error:

A database manager error occurred.[IBM][CLI Driver][DB2/NT] SQL0104N
An unexpected token "pd.proposal_id , pd.item_id , psd.year_id" was
found following "( select". Expected tokens may include:
"<space>". SQLSTATE=42601

In procedure, the part is
' select pd.proposal_id '||
' ,pd.item_id '||
' ,y.year_id '||

What is wrong? There do have spaces following 'select'.

What's that '(' before the select? Must be coming from somewhere...

--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab
Nov 12 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.