dbTalk Databases Forums  

Assign Child Package Global Variable ---

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss Assign Child Package Global Variable --- in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
System.Xml.XmlDocument
 
Posts: n/a

Default Assign Child Package Global Variable --- - 04-08-2005 , 06:15 AM






Hi

I have a Parent package (which has a Global variable ) calls the child
package.
I have made the global variabe from Parent package as "Outer Package Global
Variable "

When i use this in Child package Activex Task
DTSGlobalVariables("Child_GlobalVariable") =
DTSGlobalVariables("Parent_GlobalVariable")


The value in "Child_GlobalVariable" is not getting Updated , what could be
the reason ?




Reply With Quote
  #2  
Old   
Allan Mitchell
 
Posts: n/a

Default Re: Assign Child Package Global Variable --- - 04-09-2005 , 03:08 AM






OK

say I have two packages

Called and Caller


Caller executes Called

Caller has a Global Variable named CallingPackageGV (initial value == "I called you")
Called has a Global Variable named CalledPackageGV (initial value == "Hello World")

Caller has an ExecutePackage task pointing to the "Called" package

Called has an Active Script task that does this

Msgbox DTSGlobalVariables("CalledPackageGV").Value
Msgbox DTSGlobalVariables("CallingPackageGV").Value


The "Caller" package ExecutePackage task has

Inner Package Global Variables

Name = CalledPackageGV
Type = String
Value = ABC

Outer Package Global Variables

CallingPackageGV

When you execute the "Caller" package the "Called" package produces two messageboxes

"ABC"
"I called You"




Help any?




--

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
www.SQLIS.com - SQL Server 2005 Integration Services.
www.Konesans.com


"System.Xml.XmlDocument" <SystemXmlXmlDocument (AT) discussions (DOT) microsoft.com> wrote

Quote:
Hi

I have a Parent package (which has a Global variable ) calls the child
package.
I have made the global variabe from Parent package as "Outer Package Global
Variable "

When i use this in Child package Activex Task
DTSGlobalVariables("Child_GlobalVariable") =
DTSGlobalVariables("Parent_GlobalVariable")


The value in "Child_GlobalVariable" is not getting Updated , what could be
the reason ?






Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.