Discussion:
[nhusers] Linq-ing Calculated Properties
Azar Gurbanov
2018-01-27 04:33:13 UTC
Permalink
Hi all,

does anyone have experience implementing
this: https://hendryluk.wordpress.com/2011/09/06/nhibernate-linq-ing-calculated-properties/

I cannot get it working. Throws the following exception when the query is
executed:

NHibernate.Hql.Ast.ANTLR.InvalidPathException: Invalid path ‘x.Weight’

One workaround I found was to replace the linq parameter name, so the
following query from the example:

from parcel in Session.Query<Parcel> where parcel.Fee > 1000 select parcel;

would become:

from x in Session.Query<Parcel> where x.Fee > 1000 select x;
--
You received this message because you are subscribed to the Google Groups "nhusers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nhusers+***@googlegroups.com.
To post to this group, send email to ***@googlegroups.com.
Visit this group at https://groups.google.com/group/nhusers.
For more options, visit https://groups.google.com/d/optout.
Loading...