473,653 Members | 2,948 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

CREATE TEMPORARY TABLE AS ... ON COMMIT?

Is the ON COMMIT syntax available to temporary tables created using the
CREATE TABLE AS syntax? If not, is there a way to drop such a table at
the end of a transaction?

-tfo

--
Thomas F. O'Connell
Co-Founder, Information Architect
Sitening, LLC
http://www.sitening.com/
110 30th Avenue North, Suite 6
Nashville, TN 37203-6320
615-260-0005
---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
joining column's datatypes do not match

Nov 23 '05 #1
1 2572
On Thu, 2004-10-21 at 06:40, Thomas F.O'Connell wrote:
Is the ON COMMIT syntax available to temporary tables created using the
CREATE TABLE AS syntax?
No, but it should be. There's a good chance this will be in 8.1
If not, is there a way to drop such a table at
the end of a transaction?


DROP TABLE :)

-Neil

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Nov 23 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
4152
by: ezra epstein | last post by:
I found a post about something similar in an older release: http://archives.postgresql.org/pgsql-bugs/2002-08/msg00151.php Here's the issue. Inside a function I'm calling CREATE LOCAL TEMPORARY TABLE ds_copy_item_meta ( LIKE merchandise.item_meta EXCLUDING DEFAULTS ) on COMMIT DROP; Of course it might be that the ON COMMIT DROP is redundant, I don't know enough about temp tables. Here's the problem, however, the first call of the...
2
6968
by: Keith Watson | last post by:
Hi, we are currently implementing an application running on DB2 V7 on Z/OS using largely COBOL stored procedures, managed using WLM. Some of these stored procedures declared global temporary tables, which are declared with ON COMMIT DELETE ROWS to perform work on and then return these temporary tables to the client (which is a message driven EJB connecting via DB2 connect). The client reads the data in the result sets, creates some XML...
2
1349
by: James Foreman | last post by:
Running UDB 8.2.0 on Suse linux 8.1, as database administrator I do: declare global temporary table session.animal_noises (animal varchar(10), noises varchar(10)); insert into session.animal_noises values ('Duck', 'QUACK'); select * from session.animal_noises;
3
3449
by: vsaraog | last post by:
Hi everybody, I asked the following question but didn't get any reply. If anyone knows something about the problem, then please reply since I am really in a bind. Here is the question... I am using a Created Global Temporary Table in DB2 OS/390 version 7.1.2 with "ON COMMIT DELETE ROWS". The DBA says that I they don't have the option of "ON COMMIT PRESERVE ROWS" for Created Global Temp. tables. Anyway... I am inserting some data in...
2
2454
by: Andy S. | last post by:
Hi, I'm trying to declare and use temporary tables. I have written the following code in Java. Creating the tablespace (i can see the tablespace created using the Control Center), the temporary table and even inserting the values execute fine (even the executeUpdate while inserting returns a positive number indicating that rows have been inserted). However, when I select * from the temporary table, 0 rows are returned and the while loop...
1
1375
by: Sumanth | last post by:
the pseudo code for my update is for i = 1 to n; insert k records into temp_table; update a set c1 = (select c1 from temp_table where temp_table.pk = a.pk), c2 = ( select c2 from temp_table where temp_table.pk = a.pk) where a.pk in (select pk from temp_table)
7
2304
by: fintudet | last post by:
Hello. During some experimentation with DB2 decimal numbers representations, I have discovered very unexpected behaviour of the global temporary table. Consider this example. Such I had executed the example: # db2 -td@ -f FILENAME. When an single Insert into table fails, the table gets empty. Could anybody shed some light on this ?
2
4121
by: chettiar | last post by:
I am creating a procedure A which is creating a global temporary table DECLARE GLOBAL TEMPORARY TABLE session.temp (Service CHAR(2), CustomerServiceTypeId INTEGER) WITH REPLACE ON COMMIT PRESERVE ROWS; I am able to compile the proceudre. But when I try to compile procedure B which is referencing the temporary table in procedure A, I get the error.
1
5310
by: mpramodk | last post by:
Please find the code for creating a temporary table and access it in UDF functions. While we do this we obtain a compile time error stating "A declared temporary table cannot be used in the given context." CODE: DECLARE GLOBAL TEMPORARY TABLE SESSION.TEMP (id INT, data VARCHAR(10)) ON COMMIT PRESERVE ROWS; ----------------------------- Commands Entered ------------------------------
0
8283
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8704
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8470
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7302
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6160
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5620
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4147
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4291
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1591
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.