title: Problem connecting to MySQL from ASP in IIS
body: <p>I have a ASP application running on a IIS7 server on Windows Vista Home Premium (developing environment). The application has an ASA file to configure connections to the database:</p>
  
  <pre><code>&lt;SCRIPT LANGUAGE=VBScript RUNAT=Server&gt;
  
  Sub Application_OnStart
      Application("db") = 2
      Application("dbconnect") = "Driver={MySQL ODBC 3.51 Driver};Server=localhost;Port=3306;Option=0;Socket=;Stmt=;Uid=root;Pwd=root;CLIENT_MULTI_STATEMENTS=1;Database=appadmin;"
  End Sub
  &lt;/SCRIPT&gt;
  </code></pre>
  
  <p>Then, requests are handled in asp pages, which first load configuration with the following code:</p>
  
  <pre><code>Session("configid") = 1
  dbConnect = Application("dbconnect")
  Set Conn = Server.CreateObject("ADODB.Connection")
  Conn.Open (dbConnect)
  sql = "select * from settings where configid = "&amp;Session("configid")
  Set RS = ExecuteRecordset(sql)
  ...
  </code></pre>
  
  <p>Everything seems fine, however, on any request to the site, it logs the following error:</p>
  
  <pre><code>|11|80004005|[Microsoft][ODBC_Driver_Manager]_Data_source_name_not_found_and_no_default_driver_specified 80
  </code></pre>
  
  <p>Opening a command prompt and running "mysql -uroot -proot -D appadmin" connects to the database without problem.</p>
  
  <p>Any ideas as to what may be causing the problem?</p>