Page 1 of 1

ODBC process from dev to test with different credentials

Posted: Fri Nov 18, 2011 10:39 am
by LoganNSE
Hi,

We have two set of Oracle database for dev and test and we do have TM1 application developed in dev server via ODBC connection connecting to dev database.
NOTE: Credentials for dev and test was different.

When we deploy it in TM1 test - we have to manually open each and every process to change their credentials to point to test database as it was different from dev database, which is a neck-breaking task and we have been doing this for last 3 months and thought of automating it- however, on research ( :roll: my research) I don't fine API or a batch file will help to change the PRO file as the password was encripted.

Is there any other way or approch to change the ODBC database credentials for processes that are being deployed in test?

Thanks.

Logan

Re: ODBC process from dev to test with different credentials

Posted: Fri Nov 18, 2011 11:01 am
by qml
Store the DB credentials in a config cube in TM1 (each environment will have different string values in this cube). Put security on the cube so that only admin can access it.

Then pull the values from the cube using CellGetS and change the credentials in prolog using the variables DatasourceUserName and DatasourcePassword. You can even have different queries for the different environments (use DatasourceQuery for that).

Re: ODBC process from dev to test with different credentials

Posted: Sun Nov 20, 2011 7:46 am
by Harvey
The above post is correct.

However, I'd also add that you can have the user specify the credentials in TI parameters. Your TI could then use the credentials, by setting the DatasourceUserName and DatasourcePassword variables, and, if they are successful, save them to the credential config cube as suggested above. Only if the parameters are omitted do you attempt to look them up in the config cube.

That way, no one needs to have access to, or knowledge of, the credential config cube in order to run the TI processes. It would also allow them to be changed easily if required.

Of course, it means editing every TI process once, but you would have to do that to implement the above anyway.

Re: ODBC process from dev to test with different credentials

Posted: Mon Nov 21, 2011 8:37 am
by LoganNSE
Dear Qml and Lazarus,

Thanks a ton - it worked. :D

Added DatasourceUsername and DatasourcePassword in Prolog with corresponding values, removed hardcoded values from the main tab (preview becomes blank on doing this) as we need this same process to be deployed in different servers - got a message saying that 'Unable to Open Connection to Database' and chosen 'Keep all variables' however process ran fine without any messages.

When tried to open the same process, got the same old message saying that 'Unable to Open Connection to Database' but it didn't do any harm - everything was in place.

Thanks again.

Logan