SELECT DISTINCT(columname) and TEMP dbs
Posted in 1997
I am trying to execute a simple query such as:
SELECT DISTINCT(columnname)
FROM ANYTABLE;
There are approximately 40 million rows in ANYTABLE. The query runs
forever, and the only activity I can see is major temporary dbspace
reads and writes. I have tried forcing a light scan, but still hangs
in the temporary dbspace thrash step.
There are twenty temporary dbspaces on separate devices and
controllers, raw. The system has sixteen CPUs, several gigabytes of
memory. We are running INFORMIX-OnLine 7.20.UC2 on IRIX 6.2. ANYTABLE
is on a single device. It is a two-column (rowsize of eight bytes)
table. Statistics are fresh. UNIX sar command shows moderate activity
on the temporary chunks, but no "pegged" disks.
Anyone have any ideas on where and why this query is hanging???
-------------------------------------------------------------------
Jeff Craig | dbINTELLECT Technologies, Inc.
Senior Consultant | Golden, CO
| (303) 275-6954 ext. 8008
| email: settler@dbintellect.com
| fax: (303) 275-2134
-------------------------------------------------------------------