Thanks Ayende but I'm not sure how I use UnitOfWorkApplication let see
my simple query

public static ICollection<Customer> FindCustomers(string q){
        var dcFindCustomer = DetachedCriteria.For<Customer>("c")
                        .Add(
                                Restrictions.Or(
                                        Restrictions.Eq("c.Id", q),
                                        Restrictions.Like("c.Name", q, 
MatchMode.Anywhere))
                        );

        return Repository<Customer>.FindAll(dcFindCustomer);
}


On Jan 21, 9:57 am, Ayende Rahien <[email protected]> wrote:
> sessionFactory.Evict
>
> On Tue, Jan 20, 2009 at 6:56 PM, c.sokun <[email protected]> wrote:
>
> > I had a weir behavior in my FindAll(detachedCriteria); method where it
> > return records although the criteria match nothing.
>
> > I suspect because I am not using Cache properly so I would like to
> > know how can I manually invalidate 2nd level cache.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Castle Project Development List" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/castle-project-devel?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to