• Index
  •  » Talend Open Studio for Data Integration » Usage, Operation
  •  » Changing Context after Exporting Job Scripts

#1 2009-05-01 09:57:17

anuradha.chaturvedi
Member
Registered: 2009-04-14
Posts: 34

Changing Context after Exporting Job Scripts

Tags: [context, export, value]

Hi,

I have created a job which is having some child jobs attached. But all having same DB Connection metadata.
Job1--->Job2
Say Job1 is calling Job2 and both have same DB connections (same metadata attached from repository)

So I created a context group "DBConnection" and used that in both the jobs.
Now I exported the Parent Job(Job1) Script including its childrens by clicking on checkbox Apply Children.

Now I want to change the context variable values and deploy it in some other environment where DB connection details are different.

What I did is in Job1 .bat file I modified --"--context=DBConnection"  from its original value--"--context=Default"  as follows

cd %~dp0
java -Xms256M -Xmx1024M -cp classpath.jar; nvimigration.job1_0_1.job1 --context=DBConnection %*

And modified the connection parameters in following file
....\Job1\src\nvimigration\contexts\DBConnection_0.1.item with respective changes in DB IP and credentials.

But after making these changes also when I tried running the .bat file it was using old DB credentials only.

Please suggest if I am doing something wrong. Or there is some other way to implement the same

Thanks ,
Anuradha.

and tried to run

Offline

#2 2009-05-01 12:36:38

anuradha.chaturvedi
Member
Registered: 2009-04-14
Posts: 34

Re: Changing Context after Exporting Job Scripts

Can anybody please help me on this ..... sad

Offline

#3 2009-05-04 05:49:18

shong
Talend team
Registered: 2007-08-29
Posts: 10310
Website

Re: Changing Context after Exporting Job Scripts

Hello

See [Forum, topic 1615] Passing variable (context) value from the command line to learn how to set the value of context varaible dynamically.

Best regards

        shong


Email:shong@talend.com
Choose Talend, Enjoy Talend!
New & Event: Talend Help Center
Talend-->the leader of open source data management and application integration solutions!

Offline

  • Index
  •  » Talend Open Studio for Data Integration » Usage, Operation
  •  » Changing Context after Exporting Job Scripts

Board footer

Powered by FluxBB