0

My SSIS has Execute SQL Tasks which just calls a stored procedure. How to get count of records returned by the stored procedure?

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
  • Possible duplicate of [Count # of Rows in Stored Procedure Result, then Insert result into table](http://stackoverflow.com/questions/31973909/count-of-rows-in-stored-procedure-result-then-insert-result-into-table) – S3S Sep 08 '16 at 21:07

1 Answers1

0

In your stored procedure, you can include a SELECT statement to return the row count.

CREATE proc test_proc as
begin
    ....
    select rowcnt= 230
end

And as per the Execute SQL Task setup, I captured and attached 2 images here below.

enter image description here enter image description here

Dance-Henry
  • 923
  • 1
  • 7
  • 11