Query to two databases

Hello!

Is it possible to make query to two databases TAMINO?

Any samples will be appreciated…

Regards
Dariusz Baumann

Any helps?

Dariusz Baumann

Hi Dariusz,

it isn’t possible to query two separate databases with a single query, but you could (of course!) write two separate queries to access one database each.

Cheers,
Trevor.

it isn’t possible to query two separate databases with a single query …

-----------------------------------
OK. However in MANY other databases you can make query and join two or more tables using e.g. “SELECT …”.

TAMINO does NOT support join tables?

If “YES” please send any examples (schema, data) and query.

Thanks for support.

Best Regards
Dariusz Baumann

Hi Dariusz,

it is possible to combine the results of two separate schemas in a single query, but to provide the same behaviour as a JOIN is difficult in XPath.
You can query for any two doctypes in Tamino with one query, as long as the doctypes are in the same collection.
For example:
  /ConversionSourceOptions[@ino:id=1] | /TCM[@ino:id=1]

But - as mentioned - this is not the same as a join in the RDBMS world. (The result is two documents.)

The next option is to use Tamino’s map-to-object feature. You will find details on this in the documentation and these Forums.
This has the drawback that you must define the relationship(s) between schemas statically.

There is also a third option: take the QuiP prototype and experiment with W3C XQuery.
Using XQuery you have more powerful abilities to construct documents from multiple queries.
(This is much more “join like”.)

Good luck!
Trevor.