How to create 2 conditions from 2 datasets in row visibility SSRS
Hi Experts, 

 In ssrs, I want to create an expression for the row visibility. But, the expression will contain 2 conditions from different 2 datasets (DealStarts & RowofTrendingVisibility). I have applied a solution from online, but got an error message is 
"The Visibility.Hidden expression for the tablix Tablix9 contains an error: [BC30451] Name 'launchdate' is not declared. "
I think that there is a minor issue in my syntax. Can some one help me to correct it?  Thank you. 

=iif ((Last(MonthName("DealStarts"))=monthname(month(today())) or launchdate ("RowofTrendingVisibility")<Parameters!StartDate.Value),true, false)
April 29th, 2015 1:42pm

Hi JTan414,

I have check the expression you have provided and there are many incorrect using of this expression, please check and do some modification as below:

  1. For the MonthName function you should follow the grammar like:
    =MonthName(10,True)
    =MonthName(Month(Fields!BirthDate.Value),False)
    ="The month of your birthday is " & MonthName(Month(Fields!BirthDate.Value))
  2. You have add the dataset name "DealStarts" at the wrong place, it should like below:
    =Last(MonthName(Month(Fields!BirthDate.Value)),"DealStarts")
    or
    =Last(MonthName(Fields!IntegerValueField.Value),"DealStarts")
    This will return the last value from the dataset
  3. There is no function named launchdate, expression "launchdate ("RowofTrendingVisibility")" is incorrect and you shouldn't add the datasetname in this way.
  4. If the expression involved of conditions from two different datasets, limit kinds of functions will support to use:
     =Last(Fields!BirthDate.Value,"DataSetName")
    =First(Fields!BirthDate.Value,"DataSetName")


More details information about how to use expression in SSRS:
Expression Examples (Report Builder and SSRS)


If you still have any problem, please try to provide more details information about your requirements and also some sample data.

Regards,
Vic

Free Windows Admin Tool Kit Click here and download it now
April 30th, 2015 1:21am

Looks like this is what you're looking at

=iif (MonthName(Last(Fields!FieldName.Value,"DealStarts")=monthname(month(today())) or Max(Fields!launchdate.value,"RowofTrendingVisibility")< Parameters!StartDate.Value,true, false)
One question though is will there be only single date value in launchdate field in RowofTrendingVisibility dataset? Otherwise you need to determine what value you need out of it like firat,last,min,max etc
April 30th, 2015 1:47am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics