The result of both operations is PropertyName = null, which will always
return false.
You have to resort to HQL query with PropertyName is null 

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Craig
Sent: Wednesday, June 07, 2006 2:39 PM
To: [email protected]
Subject: [Castle-users] Selecting null fields

I'm trying to do to retrieve rows that have null values for this column this
on a domain object derived from ActiveRecordBase:

(T[])FindAllByProperty(typeof(T), "PropertyName", null);

Having had no success I tried this:

(T[])FindAllByProperty(typeof(T), "PropertyName", DbNull.Value);

Unfortunately still return zero rows. Is there a better way to do this, or I
am I making some stupid assumptions?

I apologise if this is a lame question, I'm new to ActiveRecord.

Thanks,
Craig


_______________________________________________
CastleProject-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/castleproject-users



_______________________________________________
CastleProject-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/castleproject-users

Reply via email to