I added a dialog to my wix xml file to allow the user to input database
connection information. It's possible that the database may require an
instance name, so I included a property to store the istance name. I'm
using the following SqlDatabase element:
<sql:SqlDatabase Id="Database" Server="[DBSERVER]" Database="[DBNAME]"
User="DatabaseUser" Instance="[DBINSTANCE]"
xmlns:sql="http://schemas.microsoft.com/wix/SqlExtension" />
This is just a reference to an existing database, so it's a child of
Product. I have a SqlString element inside a Component that references
this SqlDatabase. If the user leaves the Instance blank then the
SqlString is never executed (and no errors are thrown). If the user
enters a value such as a period, an error is thrown. If I remove
@Instance then the script runs fine. Most of the time the database will
be using the default unnamed instance, so I don't want the user to have to
enter anything for instance if it's not necessary. I'd like to know how
this can be accomplished.
Thanks
Chad Peck
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
WiX-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wix-users