Pages

Thursday 23 January 2014

?Prompt? Versus #Prompt#


?Prompt? versus #Prompt#
     Prompts provide the user to perform dynamic filtering, meaning the user can choose the filter criteria (within the parameters defined by the report writer) every time they run a report. This allows one report to span a wide range of user requirements. This is a basic feature that almost all reports use. The purpose of this post is not to explain how to build a prompt IBM has done a go of the Report Studio (version 10) user guide. There are two different prompt mechanisms in Cognos: ?prompt? and #prompt#. What is the difference between these two?

     Let us start with #prompt#. This is actually used in Framework Manager and is really powerful when used in Report Studio. The syntax for using the prompt macro is:
#prompt(ParameterName, Datatype, Defaultvalue, PreText, Source, PostText)#. Dissecting this: ParameterName is what you will call the prompt so that you can call back to it in other sections of the report. Datatype is the type of data that this prompt is utilizing; string, MUN (member unique name-used in dimensional reporting), numeric, token etc. Defaultvalue is the value it will pass if the user makes no selection. Pretext allows you to define something before the user makes a selection. Source is fairly obvious, it is the source. Posttext allows you to define something after the user makes a selection. #promtmany ()# can also be used to create a multi-selection dynamic prompt. 

No comments:

Post a Comment