views:

13

answers:

1

I'm curious as to how Informix (7.3) deals with temporary tables created with no log when a session is terminated without dropping those tables.

I connect using iSQL:

cat |isql db

Then, for example, I create one or more temporary tables with no log:

select first 10 * from table into temp t0 with no log;

If I don't drop this table with the normal drop table command and then exit iSQL via CTRL+C or my session gets terminated otherwise, what does Informix do with this/these temporary tables?

I summon Jonathan Leffler - the resident informix pro - again for this!

+2  A: 

I hear my name being taken in vain...wassup?

Oh...the good news is that because the data server (whether it is Informix SE or IDS) is an independent process, even if the front-end program (isql in the example) crashes out of control, the server is still running, notices that the front end has gone (eventually; it might take a second or so to notice sometimes) and then cleans up, rolling back any active transaction and dropping temporary tables and so on.

If the server itself crashes, then IDS will do the cleanup when it is restarted, but Informix SE isn't aware that it crashed and then, but only then, will the temporary table files be left lying around.

Jonathan Leffler
thanks, i can always count on you!
CheeseConQueso