NULL issue in where clause

  • Help!!!

    My query works in query analyzer but not in RS.

    My report parameter is an integer with name/values of "5"/5, "10"/10, "15"/15, "Already Expired"/null.

    I see that RS doesn't allow the use of "IS NOT NULL" so I am using the IsNothing function.

    Regardless I'm still getting an error.

    WHERE ((" & IsNothing(Parameters!Date_Range.Value) & ") AND (mytable.EXPIRY_DATE < getDate())) OR ((DATEDIFF(day, getDate(), mytable.EXPIRY_DATE) <= " & Parameters!Date_Range.Value & " AND mytable.EXPIRY_DATE >= getDate()) )

  • what error msg do you get ?! I don't know anything about RS, but if your values are integers then try using the ISNUMERIC() function instead and see if that resolves it!

    ps: where isnumeric(value) = 1...







    **ASCII stupid question, get a stupid ANSI !!!**

  • I got fed up with it and changed the parameter value to -1 instead of Null, now I just look for that value and query accordingly.

    Thanks anyway.

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply