COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: hittony on 10 Dec 2012 03:38:45 AM

Title: Prompt Button & Local Cache
Post by: hittony on 10 Dec 2012 03:38:45 AM
Hi,

I want to put a prompt button in a report page and i don't want to use local cache when i clic on it for the refreshed data.

Is it possbile ?

THX ;)
Title: Re: Prompt Button & Local Cache
Post by: Bark on 10 Dec 2012 03:55:53 AM
The local cache is a query property, you can disable but it will disable it for every run; you cannot tell not to use it only when click on the button.

Go to queries, properties pane, Use Local Cache --> No

Regards,

Bark
Title: Re: Prompt Button & Local Cache
Post by: hittony on 10 Dec 2012 04:09:48 AM
Quote from: Bark on 10 Dec 2012 03:55:53 AM
The local cache is a query property, you can disable but it will disable it for every run; you cannot tell not to use it only when click on the button.

Go to queries, properties pane, Use Local Cache --> No

Regards,

Bark

This proterty does work with run, but it doesn't work with a prompt button. A prompt button use oCV_NS_.promptAction() and a Run use oCV_NS_.getRV().RunReport(). I think this is the reason. Is there a run button or sth like that ?
Title: Re: Prompt Button & Local Cache
Post by: Bark on 10 Dec 2012 05:33:53 AM
It might be other options but I suggest either javascript or a drill-through to the same report.

Hope it helps.

Regards,

Bark
Title: Re: Prompt Button & Local Cache
Post by: hittony on 11 Dec 2012 04:38:06 AM
Quote from: Bark on 10 Dec 2012 05:33:53 AM
It might be other options but I suggest either javascript or a drill-through to the same report.

Hope it helps.

Regards,

Bark

Thx anyway Bark,

I dont like js in my reports, a drill through doesn't work either as i want.
Firstly, it can't submit parameters, so i have to auto-submit them.
Secondly, if it doesn't open in a new window, it works only the first time !

:o
Title: Re: Prompt Button & Local Cache
Post by: hittony on 11 Dec 2012 07:44:48 AM
Custom Refresh Button (http://businessintelligence.ittoolbox.com/groups/technical-functional/cognos8-l/custom-refresh-button-3622905)

But it works only if the report isn't from a drill through :-X
Title: Re: Prompt Button & Local Cache
Post by: Bark on 11 Dec 2012 09:10:53 AM
Quote from: hittony on 11 Dec 2012 04:38:06 AM
Secondly, if it doesn't open in a new window, it works only the first time !

I'm not sure what you mean by this but I've got a report that changes the database so when the user clicks on a button it changes a flag of the line I've clicked on. The report is grouped by that flag and at the beginning, the line wasn't changing groups because of the local cache and I solved it by disabling the cache and adding the drill-thru to the button.

It works for every single click, doesn't matter whether it is the first or the 10th (I've tried it).

Anyway, I'm happy you found another way.

Regards,

Bark