I have a property file in which the DB name is specified and when i run my servers they will point to the DB specified in that property file. Now i'm gonna write a script which will start all the services. But before that i just want to dynamically change the DB name in that property file by getting as command line argument of my script. Say this is the line in that property file as
Application.Database = snowdropDB
this line should be modified with the command line argument of my script. If i call the script like
startup tulipDB
first the script should modify that line of the property file as
Application.Database = tulipDB
and should start the services... plz do suggest me how to modify a line of a file thru script...
This script will allow you to use the different DB names.
OR you can define the DBs in an array inside the script. I prefer to have it in another file. I like modular scripting it makes it easier to make big changes without rewriting the whole program.