Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SQL0955C - Empty Table

Status
Not open for further replies.

atoi

Programmer
Apr 21, 2003
6
US
Environment: DB2-UDB for AIX version 7.2.4

Have a process that encounters SQL0955C errors on occasion when executing a SELECT from an empty table while nothing much else is going on in the database instance. The table in question has NEVER been populated with data. The table resides in a tablespace with other populated tables. The SELECT statement has a WHERE predicate that specifies columns NOT included in an index. RUNSTATS have been run for the table. The process is part of a packaged application, consequently, the client wants to leave the software in it's vanilla state. The DBA has adjusted SORTHEAP/SHEAPTHRES parameters in efforts to address the problem.

Does anyone have an explanation as to what might be causing this? Would creating an index for the columns in the WHERE predicate help? The problem does not happen regularly and can not be replicated on command making it difficult to debug.

TIA for any insight you may provide.

AO
 
AO,

is this SELECT as part of a CURSOR or a singleton select? Perhaps you can paste the actual statement?

Also try taking a look at the following

Increase the database configuration parameter (dbheap) to allow a larger database heap. If the number of I/O servers is near the high limit, reducing this number may also help.

Cheers
Greg
 
Greg:

The select is part of a cursor . . . the process is executing a proprietary product (SQR) that creates dynamic SQL based on it's coding language. The basic syntax of the SQL statement that is being prepared/executed is not too complex and looks something like this:

SELECT A.FLDA
, A.FLDB
, A.FLDC
, A.FLDD
FROM A_TBLNAME A
WHERE A.FLDC = ?
AND A.FLDD = ?

I'll pass along your comments to the DBA.

Thanks for your suggestion.

AO
 
Greg:

No sir, no ORDER BY or GROUP BY clause.

AO
 
AO,

is it using an index for this search or doing a table space scan?

Greg
 
Greg:

Additional tweaking of the SORTHEAP/SHEAPTHRES parameters appears to have addressed the problem.

Thanks for your input,

AO
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top