COGNOiSe.com - The IBM Cognos Community

IBM Cognos 10 Platform => Cognos 10 BI => Report Studio => Topic started by: gatorfe on 15 Feb 2012 02:50:44 PM

Title: Report Location Path in Report Studio
Post by: gatorfe on 15 Feb 2012 02:50:44 PM
Hello, a user was wondering if there is a way to add the report path location/name from Cognos Connection inside the report studio report.  For example the report location/name is Sales > East Division > Invoicing Detail Report. Is there some function that allows the user to add "Sales > East Division > Invoicing Detail Report" to the report itself like in the footer?  Thanks in advance for any suggestions!
Title: Re: Report Location Path in Report Studio
Post by: nayitian on 15 Feb 2012 03:07:07 PM
If I am understanding correctly, you can add two Layout Calculations, each holds report name and path, from Report Functions.
Title: Re: Report Location Path in Report Studio
Post by: gatorfe on 16 Feb 2012 10:05:42 AM
Hello, that worked.  Thank you!  This is what shows now at the bottom of the report

, /content/package[@name='SMT Sales Analysis']/folder[@name='Reports']/folder[@name='Spring']/folder[@name='1 Under Development']/report[@name='Cognos 10 UAT Test Report']. 

Is there any way that it can be changed to look like this instead:
'SMT Sales Analysis'/'Reports'/'Spring'/'1 Under Development'/'Cognos 10 UAT Test Report'
Title: Re: Report Location Path in Report Studio
Post by: Lynn on 16 Feb 2012 11:41:51 AM
You could try to parse the string, but the problem is that any folder structure is supported and the number of /folder entries can vary. This makes the parsing fairly complicated to code.

I did something similar once, but it was against the audit tables so I had database functions at my disposal to do the parsing. I'm not sure if a layout calculation supports terribly robust functions, but I've never tried.
Title: Re: Report Location Path in Report Studio
Post by: navissar on 16 Feb 2012 04:22:23 PM
Probably possible to use JS for parsing with regex, then it doesn't matter how many a there.
Title: Re: Report Location Path in Report Studio
Post by: ustas on 09 Mar 2012 10:09:51 PM
I keep full path to report divided to components in my DB and use it whenever need
Title: Re: Report Location Path in Report Studio
Post by: ambuj2k50 on 20 Mar 2012 07:54:46 AM
You can also use parametrized url ... inside HTML object to embed the report path. To hide the cognos connection tool tabs u can use &cc header=false etc.