Re: Role of DBSPACETEMP (II)
Posted in 2000
---- you wrote:
> Hi,
>
> More than a week ago I posted a question about the role of the envvar
> DBSPACETEMP. I got some usefull responses but I'm still not satisfied.I
> think that the documentation is not very clear about DBSPACETEMP. So
> here is my second post. Below is the output of onstat -d.
>
> Informix Dynamic Server Version 7.30.UC6 -- On-Line -- Up 16:32:08 --
> 41232 Kbytes
>
> Dbspaces
> address number flags fchunk nchunks flags owner name
> c9150158 1 1 1 1 N informix rootdbs
> c9150958 2 1 2 1 N informix logdbs
> c9150a18 3 1 3 2 N informix wocasdbs
> c9150ad8 4 2001 4 1 N T informix tempdbs
> 4 active, 2047 maximum
>
> Chunks
> address chk/dbs offset size free bpages flags pathname
> c9150218 1 1 0 25000 4145 PO-
> /dev/vg01/raboom_root
> c91505d8 2 2 0 25000 9947 PO-
> /dev/vg01/raboom_log
> c91506b8 3 3 0 125000 23 PO-
> /dev/vg01/raboom_wocas
> c9150798 4 4 0 25000 24947 PO-
> /dev/vg01/raboom_tmp
> c9150878 5 3 0 1024000 981250 PO-
> /dev/vg01/rinfaboom
> 5 active, 2047 maximum
>
> As you can see we configured a dbspace called tempdbs and a dbspace
> called rootdbs. If I create a temp table and DO NOT specify the WITH NO
> LOG option, the temp table will ALWAYS be created in the root dbspace,
> even if I specify DBSPACETEMP=tempdbs in my environment. If I create the
> temp table WITH the WITH NO LOG option however, the temp will be created
> in the dbspace that is specified through the DBSPACETEMP envvar. I can't
> imagine that this is the intented behaviour. Can someone clarify my
> problem.
It sounds okay to me Dude. But you don't give much info, such as:
1) Does your database have logging?
2) Where is your database created?
3) What sort of temp table are you creating?
I would guess the answer to 1) is 'yes', so that by default your temp table is logged. Logged tables cannot be stored in a temp dbspace. If you specify WITH NO LOG, then it will not be logged and can be stored in a temp dbspace.
As to using the rootdbs dbspace, either your database is created in that dbspace, or you are creating an implicit temp table with SELECT... INTO TEMP...?
AB
----------------------------------------------------------------
Get your free email from AltaVista at http://altavista.iname.com