title: How to run sql script to create database using Wix
body: <p>I'm running into problem creating database with Wix. The examples(see link below) i can find are all creating database first using wix and running a create table sql script. The problem is that i need to set the wix to run sql script with CREATE DATABASE to create the database and tables, and NOT to create the database first using the SqlDatabase tag in .wxs file. Is this possible to do this in Wix?  I'm using SQL Server Express. Any example on how to do this would be helpful.</p>
  
  <p><a href="http://www.rrreese.com/Article/Show/WiX%20SQL" rel="nofollow">http://www.rrreese.com/Article/Show/WiX%20SQL</a></p>
  
  <p>Example of sql script:</p>
  
  <pre><code>CREATE DATABASE My_DB
  CREATE TABLE Test (Value1 CHAR(50), Value2 INTEGER)
  CREATE INDEX TestIndex ON Test (Value1)
  </code></pre>
  
  <p>Thanks in advance. Any help is much appreciated.</p>