Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

IF/ELSE/THEN FUNCTION IS SSRS 2008 R2 Expand / Collapse
Author
Message
Posted Monday, January 21, 2013 2:06 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Thursday, February 21, 2013 9:49 AM
Points: 16, Visits: 112
How to add this Function in SSRS 2008 R2

if {Reportname.Fieldname}='yes'
then
{reportname.Amount1}
else
{reportname.amount2}

This is added in Crystal Report but i wan to add this in ssrs 2008r2 please help me
Post #1409424
Posted Monday, January 21, 2013 2:26 AM


SSChampion

SSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampion

Group: General Forum Members
Last Login: Today @ 7:29 AM
Points: 12,206, Visits: 9,168
You need to use the IIF function.

Expression Examples (Report Builder and SSRS)




How to post forum questions.
Need an answer? No, you need a question.
What’s the deal with Excel & SSIS?

Member of LinkedIn. My blog at LessThanDot.

MCSA SQL Server 2012 - MCSE Business Intelligence
Post #1409432
Posted Monday, January 21, 2013 4:18 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Tuesday, January 21, 2014 12:48 AM
Points: 10, Visits: 158
=IIF(Reportname.Fieldname="yes",reportname.Amount1,reportname.amount2)

Post #1409470
Posted Monday, January 21, 2013 10:17 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Thursday, February 21, 2013 9:49 AM
Points: 16, Visits: 112
Thank You very much it is working fine
Post #1409637
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse