Subject Re: [firebird-tools] Temporary tables and interfaces
Author Milan Babuskov
Ann W. Harrison wrote:
> The model of temporary tables that is being considered
> at the moment has them registered in RDB$RELATIONS et al,
> but visible (the tables themselves and the records in
> RDB$RELATIONS) only to the attachment/connection that created
> them.

I'd have a simple feature request to either add new field to
RDB$RELATIONS which would mark these tables as temporary, or perhaps use
the existing RDB$SYSTEM_FLAG and set it's value to 2 (ot whatever seems
appropriate).

> I suspect that works very very badly for tools that
> do connection pooling and those that use multiple connections.

Yes, it does. We're also thinking about adding multithreading (which
requires multiple connection) to FlameRobin, and it wouldn't work.


The possible solution to this (that I currently see) is to somehow
enable new connections to attach existing temp tables from some other
connection by specifying some attachment_id or something (I don't have
insight in internals of FB so I don't know)

or

Bind the temp tables with usernames, so when user xyz creates a temp
table, it stays there until he or SYSDBA drops it... i.e. it persists
accross attachments.

Regards,

--
Milan Babuskov
http://www.flamerobin.org