How to check if a parameter is NULL in SSRS?
To check if a parameter is NULL in SSRS, you have to use IsNothing()
function as shown below:
=IIF(IsNothing(Parameters!Name.Value),True,False)
The IsNothing()
function returns True
if the Paramter value is NULL , otherwise it will return FALSE.
How to check if a parameter is BLANK in SSRS?
To check if a parameter is BLANK or EMPTY in SSRS, you have two options:
Option1: Using Len
function, to check the count of string as below
=IIF(Len(Parameters!Name.Value)=0,True,False)
Option2: simply, check if the value is equal to ""
=IIF(Parameters!Name.Value="",True,False)
How to check if a parameter is NULL or BLANK in SSRS?
In your case, I would suggest using the below expression to check if a parameter is NULL OR EMPTY in SSRS.
=IIF((IsNothing(Parameters!Name.Value)=True) OR
(Parameters!Name.Value=""),Nothing,Parameters!Name.Value)