MonoRail - How to grab records where a column isn't null

Posted by Justin on Stack Overflow See other posts from Stack Overflow or by Justin
Published on 2010-05-27T01:48:06Z Indexed on 2010/05/27 1:51 UTC
Read the original article Hit count: 298

Filed under:

Hey,

In MonoRail/Active Record if I want to grab all records that have a certain column equal to null, I can do:

public static Category[] AllParentCategories()
        {
            return (FindAllByProperty("Parent.Id", null));
        }

However, what if I want to grab all records where that column doesn't equal null? I can't figure out how to do that using this FindAllByProperty method, is there another method that is more flexible or a way to grab records using a linq-like querying language?

Thanks, Justin

© Stack Overflow or respective owner

Related posts about monorail