Hi All
I am using the following link to load data into temp tables and then use them for the final load (https://stackoverflow.com/questions/5631010/how-to-create-a-temporary-table-in-ssis-control-flow-task-and-then-use-it-in-dat)
However after the first SQL Task was created the execution is failing with the following error
[Execute SQL Task] Error: Executing the query "exec dbo.PopulateFinancialRecords" failed with the following error: "Unsupported data type on parameter binding @SnapshotDate.". Possible failure reasons: Problems with the query, "ResultSet"
property not set correctly, parameters not set correctly, or connection not established correctly.
My stored proc code
SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE PROCEDURE [dbo].[PopulateFinancialRecords] AS BEGIN SET NOCOUNT ON; declare @SnapshotDate date; declare @StartDate date; declare @EndDate date; set @StartDate = @SnapshotDate set @EndDate = dateadd(ns, -100, dateadd(day, 1, @SnapshotDate)); IF OBJECT_ID('TEMPDB.dbo.#financial_records') IS NOT NULL DROP TABLE #financial_records select f.Src_id , f.create_date , f.floorplan_id , f.fee_type_id , f.amount_applied , f.responsible_business_id , f.currency_id , f.financial_record_type_id into ##financial_records from revenue f where create_date between @StartDate and @EndDate; end GO
In my SSIS Package i create a variable "populatetemptable" and its value is exec dbo.PopulateFinancialRecords. In the general settings the execute sql task looks like below
and i have the parameter mapping as below
when i run the execute task i am getting the following error , please need advice
[Execute SQL Task] Error: Executing the query "exec dbo.PopulateFinancialRecords" failed with the following error: "Unsupported data type on parameter binding @SnapshotDate.". Possible failure reasons: Problems with the query, "ResultSet"
property not set correctly, parameters not set correctly, or connection not established correctly.
Thanks