title: SSIS Data Flow Task hangs on excecution of Pre-excecute phase
body: <p>I have a Data Flow Task that is hanging on excecution. <br>
  The flow is simple, makes two queries to different tables (Both with a couple of joins), then sorts and merges the otuputs through a common id, adds a static column to all the records, saves the row count in a user variable for later use and finally inserts into a table on another DB. 
  We are using OLE DB Sources and Destination. Source is MSSQL 2000 and Destination is MSSQL 2012 <br><br>
  <b>Symptoms:</b><br>
  <li>When excecuting, the Data Flow gets the usual yellow "running" icon. However when you double click to see the Data Flow, non of the elements have any yellow, red or green mark. </li> 
  <li>This goes on for long periods of time, at first it lasted around 20 minutes, after that it started getting longer or simply not returning at all.</li>
  <li>Output shows:<br>
  <i>Information: 0x40043006 at Load Sandbox Table, SSIS.Pipeline: Prepare for Execute phase is beginning.<br>
  Information: 0x40043007 at Load Sandbox Table, SSIS.Pipeline: Pre-Execute phase is beginning.
  </i> <br> And nothing more until the excecution is stopped.
  </li>
  <li>Yes, this has worked before. And yes, we have used a single query (in a stored procedure) to do this ETL but we wanted to migrate all the steps to SSIS.</li></p>
  
  <p><b>Failed solutions:</b>
  <li>There are no lookups.</li>
  <li>Default buffer size for the task flow was increased to 40485760 then to 80971520. </li>
  <li>Default buffer max rows for task was set to 1000000. </li>
  <li>Delay Validation was set to True for the task. </li>
  <li>All elements inside the task were set Validate External Data to False. </li>
  <li>Both queries had:<br> <i>SET FMTONLY OFF;<br>
      SET NOCOUNT ON;</i><br> added at the beggining. </li>
  <li>Both queries had <i>MAXDOP</i> set to 1. </li>
  <li>Setting project's Run 64 bit Runtime to False. </li>
  <li>Changed destination load from <i>Table or View</i> to <i>Table or View - Fast load</i> with no locks or constraints. </li>
  <li>Set rows per batch to 1000 for fast load. </li>
  <li>Some work arounds propose to separate the task flow into two or more task flows. But this is not possible since what we need to do is a merge of the information found on both source queries. </li></p>
  
  <p><b>Extra bits:</b>
  I really hope someone can help me. I am fairly new to SSIS, this is the first time I use it. I usually work with Pentaho for my ETL but the client needs the solution to be implemented on SSIS. I've been battling with this issue for a couple of days now and I'm starting to run out of ideas to solve it. <br></p>
  
  <hr>
  
  <p>When ran through the command line it gets stuck too and I get the following output:</p>
  
  <pre><code>Progress: 2013-03-19 14:36:26.21
     Source: Load Sandbox Table
     Validating: 0% complete
  End Progress
  Progress: 2013-03-19 14:36:26.21
     Source: Load Sandbox Table
     Validating: 12% complete
  End Progress
  Progress: 2013-03-19 14:36:26.22
     Source: Load Sandbox Table
     Validating: 25% complete
  End Progress
  Progress: 2013-03-19 14:36:26.22
     Source: Load Sandbox Table
     Validating: 37% complete
  End Progress
  Progress: 2013-03-19 14:36:26.23
     Source: Load Sandbox Table
     Validating: 50% complete
  End Progress
  Progress: 2013-03-19 14:36:26.25
     Source: Load Sandbox Table
     Validating: 62% complete
  End Progress
  Progress: 2013-03-19 14:36:26.25
     Source: Load Sandbox Table
     Validating: 75% complete
  End Progress
  Progress: 2013-03-19 14:36:26.25
     Source: Load Sandbox Table
     Validating: 87% complete
  End Progress
  Progress: 2013-03-19 14:36:26.25
     Source: Load Sandbox Table
     Validating: 100% complete
  End Progress
  Warning: 2013-03-19 14:36:26.26
     Code: 0x80047076
     Source: Load Sandbox Table SSIS.Pipeline
     Description: The output column "ITEM_OID (1)" (47) on output "Merge Join Outp
  ut" (28) and component "Merge Join" (11) is not subsequently used in the Data Fl
  ow task. Removing this unused output column can increase Data Flow task performa
  nce.
  End Warning
  Progress: 2013-03-19 14:36:26.27
     Source: Load Sandbox Table
     Prepare for Execute: 0% complete
  End Progress
  Progress: 2013-03-19 14:36:26.27
     Source: Load Sandbox Table
     Prepare for Execute: 12% complete
  End Progress
  Progress: 2013-03-19 14:36:26.27
     Source: Load Sandbox Table
     Prepare for Execute: 25% complete
  End Progress
  Progress: 2013-03-19 14:36:26.27
     Source: Load Sandbox Table
     Prepare for Execute: 37% complete
  End Progress
  Progress: 2013-03-19 14:36:26.27
     Source: Load Sandbox Table
     Prepare for Execute: 50% complete
  End Progress
  Progress: 2013-03-19 14:36:26.27
     Source: Load Sandbox Table
     Prepare for Execute: 62% complete
  End Progress
  Progress: 2013-03-19 14:36:26.27
     Source: Load Sandbox Table
     Prepare for Execute: 75% complete
  End Progress
  Progress: 2013-03-19 14:36:26.27
     Source: Load Sandbox Table
     Prepare for Execute: 87% complete
  End Progress
  Progress: 2013-03-19 14:36:26.27
     Source: Load Sandbox Table
     Prepare for Execute: 100% complete
  End Progress
  Progress: 2013-03-19 14:36:26.31
     Source: Load Sandbox Table
     Pre-Execute: 0% complete
  End Progress
  Progress: 2013-03-19 14:36:26.31
     Source: Load Sandbox Table
     Pre-Execute: 12% complete
  End Progress
  Progress: 2013-03-19 14:36:26.31
     Source: Load Sandbox Table
     Pre-Execute: 25% complete
  End Progress
  Progress: 2013-03-19 14:36:26.34
     Source: Load Sandbox Table
     Pre-Execute: 37% complete
  End Progress
  Progress: 2013-03-19 14:36:45.69
     Source: Load Sandbox Table
     Pre-Execute: 50% complete
  End Progress
  </code></pre>
  
  <p>After that it freezes again.</p>
  
  <p><strong>SOLUTION</strong> <em>(Posting this here because I can't answer my own question for another 5 hours, I'll do it when I'm allowed to.)</em><br>
  I finally got it. <br>
  It turns out there is an issue with the validation, but not only SSIS elements go through that validation, as stated in the fourth failed solution of the question.<br>
  The CONNECTIONS also get validated and have their own Delay Validation property, which needs to be set to true. <br>
  After that the excecution time went from 40+ mins or no running to less than a minute for the full process (This is just one step of a much bigger process)<br>
  I hope people with this same problem can find this solution easily because there's a lot of people running into this problem and nearly no solutions posted online.<br><br></p>
  
  <p><strong>In a nutshell:</strong>  Check that all your elements involved in the task, <em>including</em> the DB connections have Delay Validation Property set to True.</p>