Re: [GENERAL] temp tables ORACLE/PGSQL

2005-04-29 Thread Neil Conway
Dennis Sacks wrote: The disadvantage is, you'll have to have some process for deleting old data from the table, as it will stay around and it will bite you when you get the same pg_backend_pid() again down the road. Rather than use pg_backend_id(), why not just assign session IDs from a sequence?

Re: [GENERAL] temp tables ORACLE/PGSQL

2005-04-29 Thread Tony Caduto
I am assuming you need "session varables" for a web based app right? For a standard client/server app created in something like VB or Delphi all you really need is a single connection(because most db apps are single threaded), and a temp table will stay around until that connection is closed, and

[GENERAL] temp tables ORACLE/PGSQL

2005-04-29 Thread fisher
Hi Thank You very much. As I mentioned I need temp tables for storing "sesssion variables". I plan to write functions to return suitable column value and I need them to be availabele during whole session. That makes deleteing on commit not the best solution. For example I want to keep emp_id in on

Re: [GENERAL] temp tables ORACLE/PGSQL

2005-04-28 Thread Tony Caduto
We only do the connection "refesh" in the Lightning Admin Query editorfor testing our SQL that uses temp tables. refreshing the connection eliminates the OID does not exist problems. We put everything into stored procs and use them from Delphi applications and still never use execute in our procs

Re: [GENERAL] temp tables ORACLE/PGSQL

2005-04-28 Thread Dennis Sacks
Tony Caduto wrote: This is not entirely correct. We use temp tables all the time in PLpgsql functions and never have to use execute. We have found that you have to use EXECUTE only in certain circumstances. we use this in all our functions that use temp tables, and we use PG Lightning Admin,

Re: [GENERAL] temp tables ORACLE/PGSQL

2005-04-28 Thread Steve Atkins
On Thu, Apr 28, 2005 at 01:14:58PM -0500, Tony Caduto wrote: > This is not entirely correct. We use temp tables all the time in PLpgsql > functions and never have to use > execute. We have found that you have to use EXECUTE only in certain > circumstances. > > we use this in all our functions

Re: [GENERAL] temp tables ORACLE/PGSQL

2005-04-28 Thread Tony Caduto
This is not entirely correct. We use temp tables all the time in PLpgsql functions and never have to use execute. We have found that you have to use EXECUTE only in certain circumstances. stored procedures that use temporary tables are more painful to write - you need to use EXECUTE for any S

Re: [GENERAL] temp tables ORACLE/PGSQL

2005-04-28 Thread Dennis Sacks
NO-fisher-SPAM_PLEASE wrote: Hi I used to work with Oracle and now tryin' PostgreSQL I'm a bit confused. I found that creating temp table in one session does not make it available for other sessions for the same user? Is this intended?? PostgreSQL does not support global temporary tables. This

Re: [GENERAL] temp tables ORACLE/PGSQL

2005-04-28 Thread Pavel Stehule
> Hi > I used to work with Oracle and now tryin' PostgreSQL I'm a bit > confused. > I found that creating temp table in one session does not make it > available for other sessions for the same user? Is this intended?? Yes, it's natural behave of temp. tables in PostgreSQL. The life cycle of temp

[GENERAL] temp tables ORACLE/PGSQL

2005-04-28 Thread NO-fisher-SPAM_PLEASE
Hi I used to work with Oracle and now tryin' PostgreSQL I'm a bit confused. I found that creating temp table in one session does not make it available for other sessions for the same user? Is this intended?? I was tryin to use because of lack of session and package variables in PGSQL (thats what