Querying nullable fields

Posts   
 
    
changomarcelo avatar
Posts: 62
Joined: 15-Feb-2007
# Posted on: 16-Oct-2007 19:39:42   

Hi, I need to make a query in order to return a collection of cards that have been Verified but have not been issued yet, and that they match a specific CardID.

I'm trying with the following query:


PredicateExpression filter = new PredicateExpression(CardFields.CardID == cardNumber);
filter.AddWithAnd(CardFields.DateVerified != DBNull.Value);
filter.AddWithAnd(CardFields.DateIssued == DBNull.Value);

But this is not working. Am I doing something wrong?

changomarcelo avatar
Posts: 62
Joined: 15-Feb-2007
# Posted on: 16-Oct-2007 19:59:25   

Sorry, it is working. Forget this thread! Thanks!