COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => SDK => Topic started by: kulkarni on 07 May 2010 01:49:35 PM

Title: Find datasource(s) associated with a package
Post by: kulkarni on 07 May 2010 01:49:35 PM
Is there a way to identify the datasources associated with a package?  We are trying to come up with a matrix of it (package and its datasources).  I am running short on ideas to achieve it without SDK.  Hence posted it in SDK forum.

I'd appreciate any guidance (SDK or non-SDK).  Thank you.
Title: Re: Find datasource(s) associated with a package
Post by: kulkarni on 19 May 2010 11:52:50 AM
Checking to see if anyone has ideas to implement this?
Title: Re: Find datasource(s) associated with a package
Post by: xiska on 12 Jun 2010 04:14:40 AM
Hi

There are two ways to do that. But they depending on your requirements: online or offline, with history or without.
Please remember that the datasourcename is not fixed. It can be overwritten depending on the user.

1. SDK: get the model definition of a package, parse this xml, extract the data sources and display them. This can display the history and can be used as a portlet also known as a extended application.

2. The Framework manager model is a big xml file. Write a xslt file to transform one or more model.xml file into a html file. To do this you need a xsl parser like saxon. This is the ofline version without history.

Other ways are cm Queries which needs to be exported as xml ...

My recommendation: use #1. Take the basicnav.jsp and rewrite it to your needs. Then use it like a portal tab.

Have fun.
Title: Re: Find datasource(s) associated with a package
Post by: kulkarni on 15 Jun 2010 01:07:59 PM
Currently, I am attempting to do approach #2.  Trying to gather several xml files spread over different folders and then using xslt to extract info.  I am not pleased with this approach though.

Can you explain little bit more on appraoch #1?  I am not aware of SDK methods to extract package xml from content store.  Any guidance on this is appreciated.

Thank you.