Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Mailing Lists -> Oracle-L -> Rename table transaction
Could anybody inform me how to wrap a number of rename table operations into
a transaction?
You can do this on SQL Server with
BEGIN TRANSACTION EXECUTE sp_rename 'tableA, 'tableX'
EXECUTE sp_rename 'tableB, 'tableA'
EXECUTE sp_rename 'tableX, 'tableB'
GO
COMMIT On Oracle rename table is DDL so rollback or commit is meaningless. However, we need to guarantee that all commands either succeed or fail.
Thanks
Denys van Kempen
CARTESIS http://www.cartesis.com
Great performances start with confidence (TM)
The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer.
Vous recevez ce message car vous avez communique votre adresse email au moins une fois a Cartesis. Conformement a l'article 34 de la loi Informatique et Libertes du 6 janvier 1978, vous disposez d'un droit d'opposition, d'acces et de rectification des donnees vous concernant soit par courrier a l'adresse: Cartesis - Legal Department, 23-25 rue de Berri, 75008 Paris soit par email: legal_at_cartesis.com.
-- http://www.freelists.org/webpage/oracle-lReceived on Tue Mar 15 2005 - 05:46:28 CST