title: Component Execution Order In Wix
body: <p>Is there a way to ensure, either through specifying order or by specifying dependencies, that one component will execute before another in WiX?</p>
  
  <p>Specifically, I'm trying to create a database, then, optionally, run a script on it.  My Wix looks similar to this: </p>
  
  <pre><code>&lt;ComponentGroup Id="SQLServerComponentGroup"&gt;
      &lt;Component Id="SQLServerIstallScriptWA" Guid="" &gt;
      &lt;Condition&gt;INSTALLDB&lt;/Condition&gt;
          &lt;mssql:SqlDatabase Id="dbWA" Server="localhost" Database="[DATABASENAME]" CreateOnInstall="yes" ConfirmOverwrite="yes" DropOnReinstall="no" DropOnUninstall="yes"&gt;
              &lt;mssql:SqlScript Id="dbWAScript" ContinueOnError="no" ExecuteOnInstall="yes" ExecuteOnReinstall="no" Sequence="1" BinaryKey="MSSQLCreateDBBin" /&gt;
          &lt;/mssql:SqlDatabase&gt;
      &lt;/Component&gt;
  
      &lt;Component Id="SQLServerCreateUserWA" Guid=""&gt;
          &lt;Condition&gt;INSTALLDB AND DBCREATEUSER = 1&lt;/Condition&gt;
          &lt;mssql:SqlDatabase Id="dbWA" Server="localhost" Database="[DATABASENAME]"&gt;
              &lt;mssql:SqlString Id="dbWACreateUser" ContinueOnError="no" ExecuteOnInstall="yes" ExecuteOnReinstall="no" ExecuteOnUninstall="no" Sequence="1" SQL="" /&gt;
           &lt;/mssql:SqlDatabase&gt;
      &lt;/Component&gt;
  &lt;/ComponentGroup&gt;
  </code></pre>
  
  <p>I want to ensure that the SQLServerInstallScriptWA component is executed before SQLServerCreateUserWA component.</p>