Author |
Message
|
Srisai |
Posted: Thu May 19, 2016 1:48 am Post subject: Accessing multiple databases using single configurable servc |
|
|
Newbie
Joined: 19 May 2016 Posts: 4
|
Hello ...,
Can any one help to access multiple databases using single JDBC configurable service using mapping node.Is it possible ???
I have same user id and password with both databases but the SID will for two databases....
Thank you |
|
Back to top |
|
 |
mqjeff |
Posted: Thu May 19, 2016 4:39 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
Can you use a single JDBC connection - in any Java context - to connect to different *databases*?
If so, you can configure a JDBC Configurable Service in the same way.
If not... then there's no reason to think Broker would give you features on top of JDBC. _________________ chmod -R ugo-wx / |
|
Back to top |
|
 |
Srisai |
Posted: Thu May 19, 2016 9:35 pm Post subject: |
|
|
Newbie
Joined: 19 May 2016 Posts: 4
|
thank you for reply...
I appreciate if you could help me....
i want to connect to multiple databases using single configurable service.Is it possible.If not what is the best to do that using mapping node |
|
Back to top |
|
 |
mayheminMQ |
Posted: Fri May 20, 2016 1:15 am Post subject: |
|
|
 Voyager
Joined: 04 Sep 2012 Posts: 77 Location: UK beyond the meadows of RocknRoll
|
From Knowledge Center on jdbcproviders configurable service for IIB 9.0
https://www.ibm.com/support/knowledgecenter/SSMKHH_9.0.0/com.ibm.etools.mft.doc/bn28734_.htm?lang=en
That clearly states 1 database and multiple schemas is possible. But reading through this, I have a question now.
From the same link:
Quote: |
If the specified URL format contains non-standard JDBC data source properties, such as a server identifier, specify one of five general-purpose connection attributes to define these additional properties.
For example, if connectionURLFormat = jdbc:oracle:thin:[user]/[password]@[serverName]:[portNumber]:[connectionUrlFormatAttr1], connectionUrlFormatAttr1 must contain an Oracle server identifier, which you must supply by defining the value for the property connectionUrlFormatAttr1 on the mqsicreateconfigurableservice or mqsichangeproperties command. The integration node can then substitute all the required values into the required pattern. |
Can we not then dynamically change the values and use the same jdbc connection detail? Not exactly as using jdbc service for multiple dbs at the same time but we could change it between transactions. Is my understanding correct? _________________ A Colorblind man may appear disadvantaged but he always sees more than just colors... |
|
Back to top |
|
 |
fjb_saper |
Posted: Fri May 20, 2016 2:18 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
mayheminMQ wrote: |
Can we not then dynamically change the values and use the same jdbc connection detail? Not exactly as using jdbc service for multiple dbs at the same time but we could change it between transactions. Is my understanding correct? |
Remember the configurable service is cached. In order to change any value, you'd have to bounce the Integration Node.  _________________ MQ & Broker admin |
|
Back to top |
|
 |
mayheminMQ |
Posted: Fri May 20, 2016 2:58 am Post subject: |
|
|
 Voyager
Joined: 04 Sep 2012 Posts: 77 Location: UK beyond the meadows of RocknRoll
|
thanks fjb_saber. That clears my (mis)understanding. _________________ A Colorblind man may appear disadvantaged but he always sees more than just colors... |
|
Back to top |
|
 |
Srisai |
Posted: Sun May 22, 2016 9:51 pm Post subject: |
|
|
Newbie
Joined: 19 May 2016 Posts: 4
|
hi,
could you please guide me how to change the same jdbc connection detail dynamically.I am using the same schema for multiple databases
I appreciate if i get help from anyone
Thank you |
|
Back to top |
|
 |
Srisai |
Posted: Sun May 22, 2016 10:06 pm Post subject: |
|
|
Newbie
Joined: 19 May 2016 Posts: 4
|
Hi,
I want to create a generic configurable service for accessing multiple databases.Please guide me to achieve this task
Thank you |
|
Back to top |
|
 |
mqjeff |
Posted: Mon May 23, 2016 4:35 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
Srisai wrote: |
I want to create a generic configurable service for accessing multiple databases. |
Ok. Why do you want to do this?
Also, what do you mean by 'databases'. Do you mean databases all stored on the same database management system - that is a single install of DB2/Oracle/SQLServer/etc.. on a single network endpoint?
Or do you mean multiple databases across multiple database management systems? I doubt you will find any solution in any product that will let you do that - except by writing your own code to create a set of database connections. _________________ chmod -R ugo-wx / |
|
Back to top |
|
 |
|