Quantcast
Channel: SQL Server Integration Services forum
Viewing all articles
Browse latest Browse all 24688

SSRS Expression

$
0
0

Hi,

I need to display the title for 5 sections from my report such as below:

2 records are late
10 records due today, 7/10/2018
25 records due 07/11/2018
5 records due 07/12/2018
15 records due 07/13/2018

with the expression below, always give the error, i am not sure what i have wrong here, please help.

--EXpression ---

=CStr(CountDistinct(Fields!t_orno.Value & Fields!t_oset.Value)) + " records are " + 
  IIF(Lookup(Fields!pKey.Value, Fields!pKey.Value, Fields!sortGroupBy.Value, mydts)=1,"LATE" ,
     
  IIF(Lookup(Fields!pKey.Value, Fields!pKey.Value, Fields!sortGroupBy.Value, mydts)=2,"due today, "+
  Lookup(Fields!pKey.Value, Fields!pKey.Value, Fields!dt.Value, mydts),

IIF(Lookup(Fields!pKey.Value, Fields!pKey.Value, Fields!sortGroupBy.Value, mydts)=3,"due "+
  Lookup(Fields!pKey.Value, Fields!pKey.Value, Fields!dt.Value, mydts)

 IIF(Lookup(Fields!pKey.Value, Fields!pKey.Value, Fields!sortGroupBy.Value, mydts)=4,"due "+
  Lookup(Fields!pKey.Value, Fields!pKey.Value, Fields!dt.Value, mydts)

 IIF(Lookup(Fields!pKey.Value, Fields!pKey.Value, Fields!sortGroupBy.Value, mydts)=5,"due "+
  Lookup(Fields!pKey.Value, Fields!pKey.Value, Fields!dt.Value, mydts)
))


Viewing all articles
Browse latest Browse all 24688

Trending Articles