Discussion:
Newbie Question on Variables
(too old to reply)
rminder
2008-12-01 15:51:03 UTC
Permalink
I am getting my feet wet in learning SSIS by taking over a somewhat complex
package. My question has to do with variables. In the Script Task Editor,
when I click on 'Script' on the left, on the right I see something called
ReadWriteVariables. When I enter variable names in this field, do I have
access to these variables anywhere in my package, or just the current script?

Thanks very much - Randy
Tom Moreau
2008-12-01 21:37:46 UTC
Permalink
You can access variables anywhere within a package. However, you still have
to specify whether you need read/write or just read access within a Script
task.
--
Tom

----------------------------------------------------
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON Canada
https://mvp.support.microsoft.com/profile/Tom.Moreau


"rminder" <***@discussions.microsoft.com> wrote in message news:D27769A3-DAF9-4756-9638-***@microsoft.com...
I am getting my feet wet in learning SSIS by taking over a somewhat complex
package. My question has to do with variables. In the Script Task Editor,
when I click on 'Script' on the left, on the right I see something called
ReadWriteVariables. When I enter variable names in this field, do I have
access to these variables anywhere in my package, or just the current
script?

Thanks very much - Randy
Todd C
2008-12-02 14:06:01 UTC
Permalink
Randy:
You need to define the Variables before you can use them. And when you do,
pay particular attention to the Scope of the variables. One created in the
scope of a For Each loop will not be accessible to Tasks *outside* the loop.

Right click on the Control Flow and select Variables.
--
Todd C
Post by Tom Moreau
You can access variables anywhere within a package. However, you still have
to specify whether you need read/write or just read access within a Script
task.
--
Tom
----------------------------------------------------
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON Canada
https://mvp.support.microsoft.com/profile/Tom.Moreau
I am getting my feet wet in learning SSIS by taking over a somewhat complex
package. My question has to do with variables. In the Script Task Editor,
when I click on 'Script' on the left, on the right I see something called
ReadWriteVariables. When I enter variable names in this field, do I have
access to these variables anywhere in my package, or just the current script?
Thanks very much - Randy
Continue reading on narkive:
Loading...