View Single Post
  #3 (permalink)  
Old March 9th, 2007, 10:20 PM
Flyzim Flyzim is offline
Registered User
 
Join Date: Mar 2007
Location: , , .
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

 
Quote:
quote:It can't be this difficult to set an Output variable in SSIS


You're right, it's not that difficult ;)

Just to make sure that you've done the following:
Execute SQL Task Properties:
  ConnectionType: ADO.NET
  Connection: (Local).AdventureWorks
  SQLSourceType: Direct Input
  SQLStatement: usp_GetCount
  IsQueryStoredProcedure: True
Parameter Mapping:
  Variable Name: User::MyCount
  Direction: Output
  Data Type: Int32
  Parameter Name: @OutCount

And that's it. My variable gets the count of my procedure which looks like:
Create Procedure usp_GetCount
  @OutCount Int OUTPUT
As
Select @OutCount = Count(*) From HumanResources.Department




Reply With Quote