SSIS- Set Multiple variables via a single SQL task

后端 未结 3 818
清歌不尽
清歌不尽 2021-02-09 07:14

I\'m trying to set multiple variables to the result of an SQL Query that returns a single row with multiple columns. The SQL statement is in the format of:

SELEC         


        
3条回答
  •  半阙折子戏
    2021-02-09 07:36

    In the SQL task, under General menu, set the ResultSet property to SingleRow.

    Then, in the ResultSet menu, add the variables in the order of your select clause and map the aliases with the variables. For exemple :

    SELECT 1 AS One, 2 AS Two
    

    enter image description here

提交回复
热议问题