Solved

Conditional expresssion in Matrix detail cell

Posted on 2011-02-22
2
549 Views
Last Modified: 2012-05-11
I am using SSRS 2008 and currently working on a matrix report with one column group and one row group. The column group has Month Names and the row group has product names. The detail cells in the matrix show the sales amounts for the products by months. I have a need that for the first month column in the matrix, the sales amounts need to have a different expression than the rest of the months. For ex: lets say, for the first month column, the sales amount needs tobe multiplied by 0.8 and for the subsequent months, show the sales amount as is from the dataset. How can I write an expresssion in the detail cell to conditionally identify the first column value in the matrix vs the rest? Need a sample expression that I can look at. (The above is an example scenario and so I am not looking at solutions to do this in the sql stored procs)
0
Comment
Question by:kamur
2 Comments
 
LVL 27

Accepted Solution

by:
planocz earned 500 total points
ID: 34954032
Try something like this....

=IIF(First(Fields!MyData.Value=True,(CDbl(Fields!MyData.Value) * .8), Fields!MyData.Value)
0
 

Author Closing Comment

by:kamur
ID: 34955283
Thank You planocz, it really helps. I have opened another question along the same lines for SSRS Matrix report.
0

Featured Post

Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Occasionally there is a need to clean table columns, especially if you have inherited legacy data. There are obviously many ways to accomplish that, including elaborate UPDATE queries with anywhere from one to numerous REPLACE functions (even within…
Slowly Changing Dimension Transformation component in data task flow is very useful for us to manage and control how data changes in SSIS.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.
Viewers will learn how to use the UPDATE and DELETE statements to change or remove existing data from their tables. Make a table: Update a specific column given a specific row using the UPDATE statement: Remove a set of values using the DELETE s…

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question