Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SSIS Variables not changing value?!

Status
Not open for further replies.
Sep 2, 2005
2
GB
Greetings my SQL friends,

I have a very simple package which consists of a SQL Task component and a Script Task.

The SQL Task retrieves a single value from 1 row table in one of my database and assigns that value to a variable. The Script task simply outputs the value of the variable in to a message box. I know, it's all simple stuff (I am trying to master SSIS )

The problem I have is that when I change the value of the column in my table, the value of the variable is not changing when I re-run my package. It seems to be the same value every time.

What am I doing wrong?!

Your help would be much appreciated.
 
A couple of questions:

In the Execute SQL task:

1. Are you assigning the results of the SQL Statement into a SingleRow ResultSet?
2. Are you pointing the ResultSet to a Package level variable and not a Task Level variable?

In the Script task:

1. Are you defining this variable in the ReadOnlyVariables section using the User::VarName syntax?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top