Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Creating a temporary table similar to Oracle's temporary table behaviour

Tags:

ms-access

I am looking for a way in Microsoft Access to create a temporary table whose behaviour is similar to Oracle's in that its content is gone after the mdb is closed.

As far as I can tell, it's not possible, but I am open to be corrected on this.

Should it not be possible, I am still looking for a way to use temporary table but makes sure that the temporary table and/or its content does not clutter the mdb if (for example) the mdb is not closed correctly.

like image 279
René Nyffenegger Avatar asked Nov 09 '09 17:11

René Nyffenegger


People also ask

What are the two main types of temporary tables?

There are 2 types of Temporary Tables: Local Temporary Table, and Global Temporary Table.

What is the difference between temporary table and global temporary table in Oracle?

In Oracle there isn't any difference. When you create a temporary table in an Oracle database, it is automatically global, and you are required to include the "Global" key word. The SQL standard, which defines how the term "GLOBAL TEMPORARY TABLE" is interpreted, allows for either a LOCAL or GLOBAL scope.

What are the 2 temporary tables in SQL Server?

SQL Server provides two types of temporary tables according to their scope: Local Temporary Table. Global Temporary Table.

What is an Oracle temporary table?

In Oracle a Global Temporary Table (GTT) is a permanent metadata object that holds rows in temporary segments on a transaction-specfic or session-specific basis. It is not considered normal to create and drop GTTs on the fly.


1 Answers

You will not be corrected, Microsoft Access does not directly support temporary tables. All tables created in the database must be explicitly dropped to remove them, and are visible to all users.

The "traditional" way to work around this is to use two Access databases, one with the shared data and a second, for which each user has a private copy, with user interface elements. The second database has the tables from the first one linked and any tables created in the second database are private to the user. In such a case (assuming you don't want to persist user-specific data) you can frequently empty the private database and compact it or even simply copy a new one off the network periodically (you need to do this to update the user interface when changes are made.

like image 154
Larry Lustig Avatar answered Sep 19 '22 14:09

Larry Lustig