Tuesday, 19 November 2013

Sorting Month column when it is in Jan, Feb Mar …. Format


This is the way I defined it in new data item.

case
when ([Month]='January') then 01
when ([Month]='February') then 02
when ([Month]='March') then 03
when ([Month]='April') then 04
when ([Month]='May') then 05
when ([Month]='June') then 06
when ([Month]='July') then 07
when ([Month]='August') then 08
when ([Month]='September') then 09
when ([Month]='October) then 10
when ([Month]='November') then 11
when ([Month]='December') then 12
else
0
end

How to calculate percent change for months

Calculate % change between months with relational data
Steps:--Add Order year, Month, count(Order number) in List
-- Under the query:
--create "data item1" with expression moving-total([count],2)
--create "data item2" with expression ([Data Item1] -[count])
--create "data item3" with expression ([count]- [Data Item2])
--create "% change" with expression (if ( (([Data Item3] * 1.00)/([Data Item2] * 1.00)) is null) then (1) else ((([Data Item3] * 1.00)/([Data Item2] * 1.00)) ) and add it to the List as 4th column

How to Use a Prompt Macro to Dynamically Select a Database Table


In Framework Manager, embed a prompt macro at the data item level in a Model Query Subject.
Eg:
DB Table1 = [Year 2009]
DB Table2 = [Year 2008]
Both tables have a 'Key' column and a 'Month' column.
1) Using one of the tables, create a model query subject.
2) Edit the data item definitions of the model query subject to have the following syntax.

#'[OrclYears].[Year ' + prompt('year','token','2008') + '].[MONTH]'#
#'[OrclYears].[Year ' + prompt('year','token','2008') + '].[KEY]'#

3) Create a report which uses the 'year' parameter.
Attached is a sample model and report which demonstrates this.


Using Prompt Macro for Optional and/or Required

[gosales].[COUNTRY].[COUNTRY] = #prompt('countryPrompt','string','''Canada''')#

Required Prompt Syntax
[gosales].[COUNTRY].[COUNTRY] = #prompt('countryPrompt','string')#

How to add additional column titles into a list

Use a table object that contains several lists. Show only these columns in a table cell which should have the same additional column title. You can format now some table cells like titles. They will size with the cells they own.

For details, please have a look to the attached document.

Steps:
  1. Insert a table in the report
  2. Add as much lists as needed to the table (all lists should run with the same query)
  3. Format the list cells

Monday, 11 November 2013

Hiding a list or crosstab by using a render variable

 


Instead of using a Boolean variable to handle the Render,  use a String
Variable.
1) On the main menubar, select the "View" menu and select "variables"
2) Create a new String Variable by dragging a String Variable from the Insertable Object pane to the Variables box.
2a)Set the variable syntax to:
ParamValue('DisplayPrompt')
ParamValue('DisplayPrompt')
2b) click OK
2c) Rename the Variable name in the Properties - Variable pane to a friendly name (suchas Page Render)
3) In the Values window do the following for each value you have in your prompt ('List','Crosstab','Both')
3a) Click the new button at the bottom
3b) Type in the value you are using
'List'
3c) click okay
NOTE: The values here must match your USE Values of your prompt.
4) Assign the Render variable on the object you want to display to this variable. Check the box for each item you want it to render for.

Scrolling data from Right to left in Report studio

Scrolling data from Right to left in Report studio with HTML TAG only the following thing

(
<MARQUEE>
First select Start Date and End Date, then click on Finish</MARQUEE>)