title: SSIS package working in BIDS but not with DTEXEC, error DTS_E_ADODESTFAILEDTOACQUIRECONNECTION
body: <p>I have build an SSIS package which is working well within BIDS. The package runs successfully.</p>
  
  <p>I'm now trying to execute the same package, with the same config from the command line, but it fails to acquire a connection (error 0xC0208452 : DTS_E_ADODESTFAILEDTOACQUIRECONNECTION).</p>
  
  <p>The failing connection is a ADO.Net connection to an access file that holds all failures (as I said, directly within BIDS, it works).</p>
  
  <p>I use the following command line (in a .cmd file). The X86 flag is set as I'm also using a connection to an Excel file:</p>
  
  <pre><code>@echo off
  set dtexec=%programfiles%\Microsoft SQL Server\100\DTS\Binn\dtexec.exe
  "%dtexec%" /X86 /f "myPackage.dtsx" 
  </code></pre>
  
  <p>The output is :</p>
  
  <pre><code>Error: 2011-12-05 09:47:38.94
     Code: 0xC0208452
     Source: Output Errors to access file [162]
     Description: ADO NET Destination has failed to acquire the connection {19CC1EA2-BD93-4006-919E-39A80E828BB1}. The connection may have been corrupted.
  End Error
  </code></pre>
  
  <p>The connection string used for this connection is :</p>
  
  <pre><code>Data Source=c:\path\to\errors.mdb;Provider=Microsoft.Jet.OLEDB.4.0
  </code></pre>
  
  <p>So the default mode for sharing connection is applied (16 : ShareDenyNode).</p>
  
  <p>Finally, my platform is :</p>
  
  <ul>
  <li>W2K8 R2 x64</li>
  <li>SQL 2K8 R2 x64</li>
  </ul>
  
  <p>I don't see what's going wrong with this command line. I'd appreciate some help.</p>
  
  <p>PS: just in case, I tried running as administrator, but the behavior is identical.</p>
  
  <p><strong>[Edit]</strong> Don't know if it can help, but here is the error log when using /ConsoleLog flag :</p>
  
  <pre><code>Log:
       Name: Diagnostic
       Computer: mycomputer
       Operator: domain\me
       Source Name: Jet Errors
       Source GUID: {19CC1EA2-BD93-4006-919E-39A80E828BB1}
       Execution GUID: {90BCE5BA-CF8B-49FC-8275-1F1FF70720CB}
       Message: ExternalRequest_pre: The object is ready to make the following external request: 'IDbConnection.Open(ConnectionType: System.Data.OleDb.OleDbConnection,
   System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
  ConnectionString: Data Source="c:\Path\to\errors.mdb";Provider=Microsoft.Jet.OLEDB.4.0;)'.
       Start Time: 2011-12-05 09:58:57
       End Time: 2011-12-05 09:58:57
  End Log
  Log:
       Name: Diagnostic
       Computer: mycomputer
       Operator: domain\me
       Source Name: Jet Errors
       Source GUID: {19CC1EA2-BD93-4006-919E-39A80E828BB1}
       Execution GUID: {90BCE5BA-CF8B-49FC-8275-1F1FF70720CB}
       Message: ExternalRequest_post: 'IDbConnection.Open failed'. The external request has completed.
       Start Time: 2011-12-05 09:58:57
       End Time: 2011-12-05 09:58:57
  End Log
  Log:
       Name: OnError
       Computer: mycomputer
       Operator: domain\me
       Source Name: Categories
       Source GUID: {6DD5D6E3-2256-43D5-84B8-E9C27E02694B}
       Execution GUID: {90BCE5BA-CF8B-49FC-8275-1F1FF70720CB}
       Message: ADO NET Destination has failed to acquire the connection {19CC1EA2-BD93-4006-919E-39A80E828BB1}. The connection may have been corrupted.
  
       Start Time: 2011-12-05 09:58:57
       End Time: 2011-12-05 09:58:57
  End Log
  Error: 2011-12-05 09:58:57.62
     Code: 0xC0208452
     Source: Categories To Categories Errors [162]
     Description: ADO NET Destination has failed to acquire the connection {19CC1EA2-BD93-4006-919E-39A80E828BB1}. The connection may have been corrupted.
  End Error
  Log:
       Name: OnError
       Computer: mycomputer
       Operator: domain\me
       Source Name: Categories
       Source GUID: {6DD5D6E3-2256-43D5-84B8-E9C27E02694B}
       Execution GUID: {90BCE5BA-CF8B-49FC-8275-1F1FF70720CB}
       Message: component "To Categories Errors" (162) failed validation and returned error code 0xC0208452.
  
       Start Time: 2011-12-05 09:58:57
       End Time: 2011-12-05 09:58:57
  End Log
  Error: 2011-12-05 09:58:57.64
     Code: 0xC0047017
     Source: Categories SSIS.Pipeline
     Description: component "To Categories Errors" (162) failed validation and returned error code 0xC0208452.
  End Error
  </code></pre>
  
  <p>And here is the definition of the connection from the dtsx file itself :</p>
  
  <pre><code>&lt;DTS:ConnectionManager&gt;
      &lt;DTS:Property DTS:Name="DelayValidation"&gt;0&lt;/DTS:Property&gt;
      &lt;DTS:Property DTS:Name="ObjectName"&gt;Jet Errors&lt;/DTS:Property&gt;
      &lt;DTS:Property DTS:Name="DTSID"&gt;{19CC1EA2-BD93-4006-919E-39A80E828BB1}&lt;/DTS:Property&gt;
      &lt;DTS:Property DTS:Name="Description"&gt;&lt;/DTS:Property&gt;
      &lt;DTS:Property DTS:Name="CreationName"&gt;ADO.NET:System.Data.OleDb.OleDbConnection, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&lt;/DTS:Property&gt;
      &lt;DTS:ObjectData&gt;
          &lt;DTS:ConnectionManager&gt;
              &lt;DTS:Property DTS:Name="Retain"&gt;0&lt;/DTS:Property&gt;
              &lt;DTS:Password DTS:Name="Password" Sensitive="1" Encrypted="1"&gt;AQAAANCMnd8BFdERjHoAwE/Cl+sBAAAAeUySei4110aSwp/Lg9Ry2wAAAAAIAAAARABUAFMAAAADZgAAwAAAABAAAABIrrL+3ppbrbI4ELkWjVMvAAAAAASAAACgAAAAEAAAAMgk6OFh+lWGPpsFZ0dK9k8IAAAA1HCWmIm7dIsUAAAAjjx5q2XUdjp2o+FxWAaPCEgv94M&lt;/DTS:Password&gt;
              &lt;DTS:Property DTS:Name="ConnectionString"&gt;Data Source=c:\Path\To\errors.mdb;Provider=Microsoft.Jet.OLEDB.4.0;&lt;/DTS:Property&gt;
          &lt;/DTS:ConnectionManager&gt;
      &lt;/DTS:ObjectData&gt;
  &lt;/DTS:ConnectionManager&gt;
  </code></pre>