BobRosas
asked on
If statement in Reporting Services
I'm trying to add the attached code to a Reporting Services Dataset.
When I debug the code in SQL Server the error I get is...
The isnull function requires 2 arguments..
Would you please show me what I'm doing wrong?
When I debug the code in SQL Server the error I get is...
The isnull function requires 2 arguments..
Would you please show me what I'm doing wrong?
SELECT IIF (IsNull(YEAR(tblClientInExit.ReIntakeDate)),YEAR(tblClients.OriginalStartDate),YEAR(tblClientInExit.ReIntakeDate)) AS PlaceYear,
DATEPART(quarter, tblClients.OriginalStartDate) AS PlacePeriod, tblClients.OriginalStartDate,
tblAddresses.CountyLkUpID, tblClientInExit.ReIntakeDate
FROM tblClients INNER JOIN
tblAddresses ON tblClients.ClientFileNo = tblAddresses.ClientFileNo INNER JOIN
tblClientInExit ON tblClients.ClientFileNo = tblClientInExit.ClientFileNo
ORDER BY PlacePeriod, tblClientInExit.ReIntakeDate DESC
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER