473,467 Members | 1,656 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Should a very complex SQL statement crash the instance?

SELECT columns
FROM t1
JOIN t2
Nov 12 '05 #1
10 2227
"Philip Sherman" <ps******@ameritech.net> wrote in message
news:gu***************@newssvr32.news.prodigy.com. ..
SELECT columns
FROM t1
JOIN t2
.
.
.
WHERE predicates

The from/join contains 5 tables, one of which is created from a select
statement.

The columns area contains 35 selects, some of them containing a join,
referencing a total of 40 tables.

UDB 8.1 Windows and Linux both hard crashed (complete instance shutdown)
trying to process this statement. (Yes, I have dumps from Linux and may
be able to get to the Windows dumps next week.)

Please don't ask me where this came from - I didn't write it and just
have to make it work within the next two days.

Check the SQL limits in the SQL Reference for the most tables or joins in
one statement. If you are not on fixpak 5, I would install it now.

I don't care where it came from, but the person who did it should be tarred
and feathered.
Nov 12 '05 #2
"Philip Sherman" <ps******@ameritech.net> wrote in message
news:gu***************@newssvr32.news.prodigy.com. ..
SELECT columns
FROM t1
JOIN t2
.
.
.
WHERE predicates

The from/join contains 5 tables, one of which is created from a select
statement.

The columns area contains 35 selects, some of them containing a join,
referencing a total of 40 tables.

UDB 8.1 Windows and Linux both hard crashed (complete instance shutdown)
trying to process this statement. (Yes, I have dumps from Linux and may
be able to get to the Windows dumps next week.)

Please don't ask me where this came from - I didn't write it and just
have to make it work within the next two days.

Check the SQL limits in the SQL Reference for the most tables or joins in
one statement. If you are not on fixpak 5, I would install it now.

I don't care where it came from, but the person who did it should be tarred
and feathered.
Nov 12 '05 #3
We are on FP5.

I went through the limits section of SQL REF V1 3 times and couldn't
find that particular limit. Maybe age is getting to my eyes.

Phil Sherman
Mark A wrote:

Check the SQL limits in the SQL Reference for the most tables or joins in
one statement. If you are not on fixpak 5, I would install it now.

I don't care where it came from, but the person who did it should be tarred
and feathered.


Nov 12 '05 #4
We are on FP5.

I went through the limits section of SQL REF V1 3 times and couldn't
find that particular limit. Maybe age is getting to my eyes.

Phil Sherman
Mark A wrote:

Check the SQL limits in the SQL Reference for the most tables or joins in
one statement. If you are not on fixpak 5, I would install it now.

I don't care where it came from, but the person who did it should be tarred
and feathered.


Nov 12 '05 #5
Philip Sherman wrote:
SELECT columns
FROM t1
JOIN t2
.
.
.
WHERE predicates

The from/join contains 5 tables, one of which is created from a select
statement.

The columns area contains 35 selects, some of them containing a join,
referencing a total of 40 tables.

UDB 8.1 Windows and Linux both hard crashed (complete instance shutdown)
trying to process this statement. (Yes, I have dumps from Linux and may
be able to get to the Windows dumps next week.)

Please don't ask me where this came from - I didn't write it and just
have to make it work within the next two days.

If this were IBM Informix Dynamic Server, I'd answer "No; no statement
is allowed to crash the server". The server may decline to answer,
generate errors where you can see an answer could be produced, or any
of a number of other things (not excluding producing the right
answer), but the server may not crash because of what you asked it to
do. If there was a question of exceeding a server limit, the server
is allowed to diagnose this, but it still isn't allowed to crash.

I imagine the DB2 development team feels somewhat similarly about DB2.

--
Jonathan Leffler #include <disclaimer.h>
Email: jl******@earthlink.net, jl******@us.ibm.com
Guardian of DBD::Informix v2003.04 -- http://dbi.perl.org/

Nov 12 '05 #6
Philip Sherman wrote:
SELECT columns
FROM t1
JOIN t2
.
.
.
WHERE predicates

The from/join contains 5 tables, one of which is created from a select
statement.

The columns area contains 35 selects, some of them containing a join,
referencing a total of 40 tables.

UDB 8.1 Windows and Linux both hard crashed (complete instance shutdown)
trying to process this statement. (Yes, I have dumps from Linux and may
be able to get to the Windows dumps next week.)

Please don't ask me where this came from - I didn't write it and just
have to make it work within the next two days.

If this were IBM Informix Dynamic Server, I'd answer "No; no statement
is allowed to crash the server". The server may decline to answer,
generate errors where you can see an answer could be produced, or any
of a number of other things (not excluding producing the right
answer), but the server may not crash because of what you asked it to
do. If there was a question of exceeding a server limit, the server
is allowed to diagnose this, but it still isn't allowed to crash.

I imagine the DB2 development team feels somewhat similarly about DB2.

--
Jonathan Leffler #include <disclaimer.h>
Email: jl******@earthlink.net, jl******@us.ibm.com
Guardian of DBD::Informix v2003.04 -- http://dbi.perl.org/

Nov 12 '05 #7
> I imagine the DB2 development team feels somewhat similarly about DB2.
Absolutely and unconditionally!!

Having that said Wndows (I don't know about Linux) reacts in a very
alergic way to stack overflow and there is precious little DB2 can do to
soften the blow once the stack is exceeded.
We have seen (and fixed) Windows stack overflows in stress testing for
VERY long chains of predicates such as:
prd1 AND prd2 AND prd2 AND .. AND prdn (we are talking hundreds in my
experience)

First assure you are on FP5. If the problem persists please contact
support so we can fix it.
There also is a db2 utility you can use to increae the stack size.
- which's name I keep forgetting :-(

Cheers
Serge

--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab
Nov 12 '05 #8
> I imagine the DB2 development team feels somewhat similarly about DB2.
Absolutely and unconditionally!!

Having that said Wndows (I don't know about Linux) reacts in a very
alergic way to stack overflow and there is precious little DB2 can do to
soften the blow once the stack is exceeded.
We have seen (and fixed) Windows stack overflows in stress testing for
VERY long chains of predicates such as:
prd1 AND prd2 AND prd2 AND .. AND prdn (we are talking hundreds in my
experience)

First assure you are on FP5. If the problem persists please contact
support so we can fix it.
There also is a db2 utility you can use to increae the stack size.
- which's name I keep forgetting :-(

Cheers
Serge

--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab
Nov 12 '05 #9
I see nothing untoward about a 40 table query. And obviously DB2 should not
be crashing.

As Serge says, check you're on 8.1.5, then open a PMR against the bug.

"Mark A" <ma@switchboard.net> wrote in message
news:4G******************@news.uswest.net...
"Philip Sherman" <ps******@ameritech.net> wrote in message
news:gu***************@newssvr32.news.prodigy.com. ..
SELECT columns
FROM t1
JOIN t2
.
.
.
WHERE predicates

The from/join contains 5 tables, one of which is created from a select
statement.

The columns area contains 35 selects, some of them containing a join,
referencing a total of 40 tables.

UDB 8.1 Windows and Linux both hard crashed (complete instance shutdown)
trying to process this statement. (Yes, I have dumps from Linux and may
be able to get to the Windows dumps next week.)

Please don't ask me where this came from - I didn't write it and just
have to make it work within the next two days.
Check the SQL limits in the SQL Reference for the most tables or joins in
one statement. If you are not on fixpak 5, I would install it now.

I don't care where it came from, but the person who did it should be

tarred and feathered.

Nov 12 '05 #10
I see nothing untoward about a 40 table query. And obviously DB2 should not
be crashing.

As Serge says, check you're on 8.1.5, then open a PMR against the bug.

"Mark A" <ma@switchboard.net> wrote in message
news:4G******************@news.uswest.net...
"Philip Sherman" <ps******@ameritech.net> wrote in message
news:gu***************@newssvr32.news.prodigy.com. ..
SELECT columns
FROM t1
JOIN t2
.
.
.
WHERE predicates

The from/join contains 5 tables, one of which is created from a select
statement.

The columns area contains 35 selects, some of them containing a join,
referencing a total of 40 tables.

UDB 8.1 Windows and Linux both hard crashed (complete instance shutdown)
trying to process this statement. (Yes, I have dumps from Linux and may
be able to get to the Windows dumps next week.)

Please don't ask me where this came from - I didn't write it and just
have to make it work within the next two days.
Check the SQL limits in the SQL Reference for the most tables or joins in
one statement. If you are not on fixpak 5, I would install it now.

I don't care where it came from, but the person who did it should be

tarred and feathered.

Nov 12 '05 #11

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

303
by: mike420 | last post by:
In the context of LATEX, some Pythonista asked what the big successes of Lisp were. I think there were at least three *big* successes. a. orbitz.com web site uses Lisp for algorithms, etc. b....
17
by: Chris Travers | last post by:
Hi all; I just made an interesting discovery. Not sure if it is a good thing or not, and using it certainly breakes first normal form.... Not even sure if it really works. However, as I am...
10
by: xixi | last post by:
i have db2 udb v8.1 on windows 64 bit 2003 server, after db2 server start , i found this in the db2diag.log, is this error? 2004-05-05-15.28.30.780000 Instance:DB2 Node:000...
5
by: NG | last post by:
Hi, We are having DB2-V7.2 DB on AIX 5.2 machine. Recently we upgraded our system to fixpack 13 and activated activate AIX asynchronous IO function. Our DB is going to crash recovery with...
5
by: Martin Lacoste | last post by:
There's likely not a simple answer for this, I know, but, I thought I'd try anyways... Background.. I've been racking my brain with some queries that I thought were straightforward, but have...
175
by: Ken Brady | last post by:
I'm on a team building some class libraries to be used by many other projects. Some members of our team insist that "All public methods should be virtual" just in case "anything needs to be...
2
by: Racerx | last post by:
Hi All : I use db2 8.1 fixpack 3 on AIX. I recieved the following message in the diaglog ====================================================== ADM7513W Database manager has started. ...
3
by: Eric Davidson | last post by:
DB2 9.5 I keep geting the message. SQL0101N The statement is too long or too complex. SQLSTATE=54001 When one of my sql statements takes over 60 seconds to compile the sql statement. Is...
10
by: timor.super | last post by:
Hi all, Imagine I've an array of int : int anArray = new int; I want to extract all the integer that are superior to 500 I can do :
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.