Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Question-Synonym/View Definition Modifications

Question-Synonym/View Definition Modifications

From: Wesley M. Stephens <wms_at_ornl.gov>
Date: 1997/03/27
Message-ID: <333A73A1.3C37@ornl.gov>#1/1

I have a situation where I need to perform a periodic reload of a set of tables. I am flush with disk space and I would like to keep two copies of each table - say A1 and A2. The tables have identical definitions. I would like for my applications to use the data in table A1 but to know the table as simply A. I realize I can use either a synonym (best choice) or a view to accomplish this.

My problem is this. I want to completely reload the second table (A2) while my applications are using A1, and when the reload has been verified as being good, I want to redo the synonym or view to point to A2. In this manner the applications experience minimum "downtime" because of the reload. Of course when I redo the synonym or view definition virtually every object that references the synonym or view is marked as invalid, pending re-compiliation.

Does anyone know how I can accomplish this "table rename" in a smooth manner? It is analagous to the ancient method of renaming master files after an update was performed on them - a simple thing to do with a file system but seemingly impossible with an Oracle database!

Thanks for any help...

-wesley

-- 
+-------------------------------------------------------------------+

| Wesley M. Stephens Phone: (423) 576-1933 |
| Lockheed Martin Energy Systems Fax: (423) 576-0099 |
| P.O. Box 2009 Email: wms_at_ornl.gov |
| 701 Scarboro |
| Oak Ridge, Tennessee, 37831-8227 |
+-------------------------------------------------------------------+
Received on Thu Mar 27 1997 - 00:00:00 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US