Page 1 of 1

Importing Whole Project

Posted: Mon Feb 18, 2008 7:32 am
by edsxpedx
Hi All,

I have exported whole project from production which is in DataStage 6.1.1. Now I have to import whole project to new Development server which is in 7.5.1.1. In this process I got a requirement to change the production database login information to development database login information for all the jobs(Around 900 jobs). How can I do this simple instead of changing in every job.

Thanks
Venu

Posted: Mon Feb 18, 2008 7:58 am
by chulett
Best answer would have been to use Job Parameters for this information making the whole point moot. However, still shouldn't be all that hard - use your favorite text editor and search/replace old to new values in the .dsx before you import it.

Posted: Mon Feb 18, 2008 10:11 am
by edsxpedx
Thanks a lot for your infromation.

Posted: Mon Feb 18, 2008 11:30 am
by vivekgadwal
Or...design a DS Job that sources the export file and using EReplace function, replace the required information. It would go something like this...

Source would be the .dsx file
Target again would be the .dsx file...file name different of course
In the transformer use the Ereplace function to find and replace the string that you need.
Syntax would be like this:

Code: Select all

 Ereplace(<Col Name>, "<String to be replaced>", "<New String>")
Now the only issue that I can see with this is to replace the Password. But, at least this will work for replacing the SID and USER NAME.

Posted: Mon Feb 18, 2008 5:00 pm
by jdmiceli
If you still have it in text file format and have Perl available, follow this link: viewtopic.php?t=113429&highlight=perl+scripts

Search for the script named ReplaceParameters.pl and follow the instructions. It is quick and easy.