No transaction.

Standard operating procedure is that the admin makes a full backup before an 
update. Point. Admins not doing backups - should be fired.

Run the script. Use transactions for small data changes - but nothing else. If 
something goes wrong, tell the admin to put in his backup ;)

Do NOT make automated backups unless your app is small / the data is trivial. A 
900gb database is nothing I want an installer to back up by chance ;)

Installers should warn (did you do a backup?), then do their business in the 
database.

Roll back - often not possible. Don't bother, so to say ;)

Thomas

-----Original Message-----
From: lewisv [mailto:le...@nitorco.com] 
Sent: 07 May 2010 15:10
To: wix-users@lists.sourceforge.net
Subject: [WiX-users] transactions in db scripts


I am wondering about how you guys handle transactions in db upgrade scripts.

>From what i have seen sql server, does not allow create/alter/drop 
>functions
in transactions unless you have some flags sets. 

First am i correct with this?
Next how do you guys go about updating the db? Should i surround my script with 
a transaction? I would imagine the transaction will get quite large with db 
changes etc... 
Or do i just let the scripts go and assume that they will work. - I am planning 
on backing up the db before i start the install anyway, so even if it fails we 
could just overwrite it with the backup ( which would be manual, but at least 
the db is not in a half upgraded state )

Is there a good clean way to rollback if there is an error with the install?

Thanks.

--
View this message in context: 
http://windows-installer-xml-wix-toolset.687559.n2.nabble.com/transactions-in-db-scripts-tp5019222p5019222.html
Sent from the wix-users mailing list archive at Nabble.com.

------------------------------------------------------------------------------

_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

------------------------------------------------------------------------------

_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to