Questions tagged [execute-sql-task]

Execute SQL Task in SSIS is used to execute SQL statements or stored procedures in a relational database.

Execute SQL Task in SSIS is used to execute SQL statements or stored procedures in a relational database. This Task need a connection manager to establish a connection with a data source and it supports several data sources other than SQL Server.


References and helpful links

66 questions
4
votes
1 answer

SSIS truncate table fails; delete from succeeds

I have an SSIS package where I want to clear a staging table and repopulate it. I have created an Execute SQL Task of TRUNCATE TABLE TABLE_NAME that fails with the error: Table does not exist or you do not have permission If I alter the task to…
Eva Donaldson
  • 385
  • 4
  • 18
4
votes
3 answers

How to use a variable value created in an Execute SQL Task in Precedence Constraint Editor?

I need to run n-multiple Execute SQL Task based on n-multiple variable value (isnull true or false). This variable is created in a ssms script in the previous execute sql task (CONDITIONAL QUERY). How can I output the variable value from the ssms…
Boels Maxence
  • 349
  • 3
  • 16
3
votes
1 answer

How to use output parameter in SSIS execute sql task from a stored procedure

Using a parameter, @IsSuccess in stored proc. How to use that @IsSuccess parameter in SSIS Execute SQL Task and take that as output from that component to another component?
3
votes
1 answer

Package part debugging is not supported when starting SSIS package

This very strange issue. When I press the start button to execute the SSIS project it shows "Package part debugging is not supported" and nothing else. I create a control flow with the data flow task and execute SQL task. I have a simple use case to…
3
votes
1 answer

SSIS Execute SQL Task multi step with parameter mapping

I have a DTSX file that has an update statement that is selecting from itself in the update statement and it is filling up the temp DB. It is using parameter mapping for a variable in the update statement. I rewrote it to first run the select…
markmccoid
  • 241
  • 2
  • 7
3
votes
1 answer

Execute SQL Task output parameter vs ResultSet

We have parameter direction as output in parameter binding and at the same time we do have result binding. So if we are having output variable or return type variable which will be available at output, so why do we need Result binding then.
Kashish Aneja
  • 41
  • 1
  • 6
3
votes
1 answer

Why is the value of a variable null inside a foreach loop container

I have a package that has a foreach file enumerator. Now I have a variable called EmailTo which is populated by an execute sql task outside the foreach container placed just before the loop container since i only need to run the execute sql task…
Errol Paleracio
  • 614
  • 1
  • 7
  • 21
3
votes
2 answers

Read file in SSIS Project into a variable

My SSIS projects tend to run queries that require changes as they move between environments, like the table schema might change or a value in the Where clause. I've always either put my SQL into a Project Parameter, which is hard to edit since…
Sam Alex
  • 79
  • 2
  • 11
3
votes
2 answers

Not able to recognize a table variable in ssis sp

I have created a variable in ssis called Vpop_summary_table. I have used this variable in a sql statement. my variable Vpop_summary_table is expected to give value [dbo].[2019-02-02_pop_table] It is fine in ssis. DECLARE @Vpop_summary_table…
3
votes
1 answer

SqlStatementSource expression vs Variable Source Type

I use SSIS in VS 2017 and SQL Server 2016. I would like to know what is the difference between the following methods to for setting SQLStatement's value in Execute SQL Task: First Way Declare a variable Configure Execute SQL Task like…
Ardalan Shahgholi
  • 11,967
  • 21
  • 108
  • 144
3
votes
2 answers

Return single row single value result set of Execute SQL task as an input to another execute SQL task in SSIS

I need to pass the single value result of an execute SQL task as the input to another. I need to have to separate tasks since I need 2 different connections. (both SQL Server, but different environments)
2
votes
1 answer

SSIS package insert data from CSV file to a staging table and then move from a staging table to a main table with a Site Column

I have a CSV file that successfully moves from Source File to a staging table in a Data Flow Task from a sequence container. There will be a few sequences of this. I then need to move this data from the staging table to the main table that contains…
Boltz
  • 135
  • 1
  • 1
  • 5
2
votes
1 answer

Extract filename and update table in SSIS Foreach Loop Container

I have an SSIS package that has this Foreach Loop Container(with File Enumerator) that reads from a folder with multiple CSVs file and then upload the data into a flat table. This is working fine but my problem is trying to also extract the…
2
votes
3 answers

Error with execute SQL task when using output parameter

I want to retrieve the latest date from a SQL Server table. In an "Execute SQL task" I have the following SQL Statement: SELECT ? = MAX(MYDATE) --SQL data type of this column is datetime FROM TBLLOG WHERE COMPLETED = 1 Under the parameter mapping…
variable
  • 8,262
  • 9
  • 95
  • 215
2
votes
2 answers

Azure Data Factory Set Parameter with SQL Query

What is the alternative to SSIS' Execute SQL Task in ADF? I've created a Pipeline parameter called ExtractDate (i know there isn't a date datatype option so I'm using a string datatype here) that I want to populate with the result of a SQL Query and…
Geezer
  • 513
  • 5
  • 17
1
2 3 4 5