NotSupportedException is raised when trying to execute a query

16 views
Skip to first unread message

antoni....@webwerx.pl

unread,
May 21, 2012, 5:09:40 AM5/21/12
to nhusers
Hello everyone,

I am currently creating an application using the nHibernate and I've
encountered a strange problem with one of the LINQ queries.

NotSupportedException is being thrown when I try to execute something
like this:

var result = _productRepository.FindAll().OrderBy(p =>
p.UnitsInStock).Take(63).Select(p => p.ProductName);

Does anyone have an idea why does it happen? I can provide the source
code if necessary.

I will appreciate any help. :)

Best regards,
Antoni Marasek

Oskar Berggren

unread,
May 21, 2012, 9:09:26 AM5/21/12
to nhu...@googlegroups.com
Does it match this issue?
https://nhibernate.jira.com/browse/NH-2588


2012/5/21 antoni....@webwerx.pl <antoni....@webwerx.pl>:
> --
> You received this message because you are subscribed to the Google Groups "nhusers" group.
> To post to this group, send email to nhu...@googlegroups.com.
> To unsubscribe from this group, send email to nhusers+u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/nhusers?hl=en.
>

antoni....@webwerx.pl

unread,
May 21, 2012, 11:59:56 AM5/21/12
to nhusers
Hello Oskar,

Thank you very much for your answer - I really appreciate it.

I think your're right - solution from your link matches mine. I've
seen in here (https://github.com/nhibernate/nhibernate-core/pull/94)
that someone has already solved it. However, I have no idea how to use
his code - could you help me with it too, please ?

Best regards,
Antoni Marasek

On May 21, 3:09 pm, Oskar Berggren <oskar.bergg...@gmail.com> wrote:
> Does it match this issue?https://nhibernate.jira.com/browse/NH-2588
>
> 2012/5/21 antoni.mara...@webwerx.pl <antoni.mara...@webwerx.pl>:

Alexander I. Zaytsev

unread,
May 23, 2012, 10:44:26 AM5/23/12
to nhu...@googlegroups.com
Hi,  Antoni

I've merged this pull request to the master. So build is available on the teamcity:  http://teamcity.codebetter.com/viewLog.html?buildId=45061&tab=artifacts&buildTypeId=bt7## 

понедельник, 21 мая 2012 г., 21:59:56 UTC+6 пользователь antoni....@webwerx.pl написал:
> > To unsubscribe from this group, send email to nhusers+unsubscribe@googlegroups.com.

antoni....@webwerx.pl

unread,
May 23, 2012, 12:21:02 PM5/23/12
to nhusers
Hi Alexander,

Thanks a lot ! It worked and solved my problems :)

Best regards,
Antoni Marasek

On 23 Maj, 16:44, "Alexander I. Zaytsev" <haz...@gmail.com> wrote:
> Hi,  Antoni
>
> I've merged this pull request to the master. So build is available on the
> teamcity:  http://teamcity.codebetter.com/viewLog.html?buildId=45061&tab=artifac...
> > nhusers+u...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages