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

8.2 - recursive sql procedure

P: n/a
Recursive call possible only through dynamic sql (prepare/execute)?

Andy
Nov 12 '05 #1
Share this Question
Share on Google+
6 Replies


P: n/a
andreyp#Antispam@mapsitnA#it4profit.com wrote:
Recursive call possible only through dynamic sql (prepare/execute)?

Andy

Yes, is that a problem? I think SQL PL also supports EXECUTE IMMEDIATE....

Cheers
Serge
Nov 12 '05 #2

P: n/a
Serge!

When migrate from 7.2 - YES! And SQL0340 - TOO! I don't understand why i
can't define 2 identically cursors with primitive constraction like this

declare c1 cursor for
with params(a,b,c) as ( values(a,b,c) )) ...
;

declare c2 cursor for
with params(a,b,c) as ( values(a,b,c) )) ...
;

SQL0340N The common table expression "AVP.PARAMS" has the same identifier
as
another occurrence of a common table expression definition within the same

statement. LINE NUMBER=82. SQLSTATE=42726

And where I can found notes about this "features"?

Best regards,
Andy

P.S. Usage client 8.2 => server 7.2 - ( | ) ! :-(

But CC - more better and better! 10 years more and its will be useful. ;-)
O! trap on some recursive sql fixed... But I have 3 more for easy trap
db2. I need it for testing cluster HA enviroment...

Nov 12 '05 #3

P: n/a
I'm not sure I understood everything...

The error you observe with the duplicate name is a bug.
Please contact support and we get it fixed.

If you observe traps in DB2 and you do not call support? How is DB2
development supposed to fix them? They will hang around until DB2 V22!

When dealing with SQL Procedures the client version plays no role.
All the interesting stuff happens on the server.

Cheers
Serge
Nov 12 '05 #4

P: n/a
Serge! Sorry about my terrible English. My native language is C++. (c)

For register apar I need recreate situation. When it's possible I do it
(look this conf, for example). But if query based on large and non
reproduced structure...

I have a lot developers who can wrote crasy query. I often simple rewrite
query and solve trap. Long time ago we spoke about using me as tester. May
be You remember. :-)

8.2 client -> 7.2 server.

- in many applications I got SQL0351N
- RUNSTATS ON TABLE xxx WITH DISTRIBUTION AND DETAILED INDEXES ALL
SHRLEVEL CHANGE;
SQL2310N The utility could not generate statistics. Error "-1651" was
returned.

and many other

Now I can't use my favorites software in normal mode. I need use two
workstation or vmware with different clients.
Best regards,
Andy
DB2 bugshunter :-)

msn: a_panskikh < av-av > h o t m a i l . c o m
icq: 2 1 - 5 9 6 - 2 1 3

Nov 12 '05 #5

P: n/a
andreyp#Antispam@mapsitnA#it4profit.com wrote:
For register apar I need recreate situation. When it's possible I do it
(look this conf, for example). But if query based on large and non
reproduced structure... ..-------------------------------------------------------------------.
| You don't need to able to recreate to raise a PMR and get an APAR |
'-------------------------------------------------------------------'
We very much like you to because it is so much easier to debug using a
debugger than to read the coffee grounds, but that's not the point.
I have a lot developers who can wrote crasy query. I often simple rewrite
query and solve trap. Long time ago we spoke about using me as tester. May
be You remember. :-) And then there are the customers you call every error a trap and scare
the living daylights out of the rest of us.....
8.2 client -> 7.2 server.

- in many applications I got SQL0351N
- RUNSTATS ON TABLE xxx WITH DISTRIBUTION AND DETAILED INDEXES ALL
SHRLEVEL CHANGE;
SQL2310N The utility could not generate statistics. Error "-1651" was
returned.

SQL1651N The request cannot be executed because the DB2 server
version does not support this functionality.

Explanation:

Some new functionality is not supported against older DB2 server
versions. Another possible cause of this error could be the
request referenced objects with qualifiers of length that exceeds
the support of the server version.

User Response:

Execute the request against a DB2 server where the latest DB2
server version has been installed, or upgrade the server to the
latest DB2 server version.

db2 =>
Nov 12 '05 #6

P: n/a
andreyp#Antispam@mapsitnA#it4profit.com wrote:
For register apar I need recreate situation. When it's possible I do it
(look this conf, for example). But if query based on large and non
reproduced structure... ..-------------------------------------------------------------------.
| You don't need to able to recreate to raise a PMR and get an APAR |
'-------------------------------------------------------------------'
We very much like you to because it is so much easier to debug using a
debugger than to read the coffee grounds, but that's not the point.
I have a lot developers who can wrote crasy query. I often simple rewrite query and solve trap. Long time ago we spoke about using me as tester. May be You remember. :-) And then there are the customers you call every error a trap and scare
the living daylights out of the rest of us.....
8.2 client -> 7.2 server.

- in many applications I got SQL0351N
- RUNSTATS ON TABLE xxx WITH DISTRIBUTION AND DETAILED INDEXES ALL
SHRLEVEL CHANGE;
SQL2310N The utility could not generate statistics. Error "-1651" was
returned.

SQL1651N The request cannot be executed because the DB2 server
version does not support this functionality.

Explanation:

Some new functionality is not supported against older DB2 server
versions. Another possible cause of this error could be the
request referenced objects with qualifiers of length that exceeds
the support of the server version.

User Response:

Execute the request against a DB2 server where the latest DB2
server version has been installed, or upgrade the server to the
latest DB2 server version.

db2 =>
Nov 12 '05 #7

This discussion thread is closed

Replies have been disabled for this discussion.