Fabio,

I guess that was what I was originally looking for in the documentation. I was totally aware of the fact that by moving to NH3 and using the 'embedded linq-provider' that likely there would be upgrade issues. What I was looking for was:

1. Is it expected that NH3 users would be expected to switch to the embedded provider or have the option of using either. In other words, will nhibernate.linq be dropped?

2. To move from nhibernate.linq 1.0 to nh3 embedded linq provider, what would be the required code changes. For example, change references, change linq to Query, and then what? Are they entirely different, is the new embedded linq-provider meant to be a replacement, or something in between?

3. Is there any documentation on using the embedded linq-provider or should I just be expecting it to work like any other linq provider?

Thanks,
Kevin

On 10-08-06 10:32 AM, Fabio Maulo wrote:
Kevin,
What you have changed is not only 2.1.2 to 3.
You have removed a reference and changed the code of the query, that mean that you are using NH3 embedded linq-provider that is completely different than what you was using in NH2.1.2.

Please, create a little failing test and add it to our JIRA.


On Fri, Aug 6, 2010 at 1:27 PM, Kevin Anderson <[email protected] <mailto:[email protected]>> wrote:

    This code was working with 2.1.2, it only broke when I changed to
    3. It is an ICollection Contains so it should be working.

    I will work on a test case.


    On 10-08-06 10:21 AM, Fabio Maulo wrote:
    Previously ?

    btw... Queryable.Contains, Enumerable.Contains, ICollection<>.Contains
    are supported.
    If you have a failing test we can check your case.


    On Fri, Aug 6, 2010 at 1:13 PM, Kevin Anderson
    <[email protected] <mailto:[email protected]>>
    wrote:

        I am sorry Fabio, I am not sure I understand. Are you saying
        that a change needs to be made in the nh3 trunk code to
        handle this case that was previously working?

        I don't have a test case, did you want a unit test or stand
        alone type test case?


        On 10-08-06 10:01 AM, Fabio Maulo wrote:
        contains should be implemented in trunk.
        Have you a test case?

        On Fri, Aug 6, 2010 at 12:42 PM, Kevin Anderson
        <[email protected] <mailto:[email protected]>>
        wrote:

            Yes, I have code that is now broken and I am not sure why:

                           return new List<JobType>(
                                from jobType in session.Query<JobType>()
                                where
            securityContext.CurrentUser.Disciplines.Contains(jobType.Discipline)
                                select jobType);

            This code was working with nh 2.1.2GA but now I get
            "Specified method
            is not supported".

            When I rewrote it to use QueryOver instead:

                           return session.QueryOver<JobType>()
                               .Where(x =>
            securityContext.CurrentUser.Disciplines.Contains(x.Discipline))
                               .List();

            This way I get a more descriptive message:

            Unrecognised method call:
            
System.Collections.Generic.ICollection`1[[PD.Insulation.Domain.Discipline,
            PD.Insulation.Domain, Version=0.0.0.0, Culture=neutral,
            PublicKeyToken=null]]:Boolean
            Contains(PD.Insulation.Domain.Discipline)




            On Fri, Aug 6, 2010 at 8:46 AM, James Gregory
            <jagregory.com <http://jagregory.com>@gmail.com
            <http://gmail.com>> wrote:
            > Is there anything in particular you're having trouble
            with?
            >
            > On Aug 6, 3:24 pm, Kev <[email protected]
            <mailto:[email protected]>> wrote:
            >> Now that nh3 has released a new/updated linq
            provider, I was wondering
            >> if there are a list of differences between this
            version (nh3 linq) and
            >> nhibernate.linq 1.0? I am trying to change to nh3 but
            there is
            >> obviously more involved than changing session.linq to
            session.Query.
            >>
            >> A pointer to some documentation would be fantastic...
            >>
            >> TIA
            >
            > --
            > You received this message because you are subscribed
            to the Google Groups "nhusers" group.
            > To post to this group, send email to
            [email protected] <mailto:[email protected]>.
            > To unsubscribe from this group, send email to
            [email protected]
            <mailto:nhusers%[email protected]>.
            > For more options, visit this group at
            http://groups.google.com/group/nhusers?hl=en.
            >
            >

            --
            You received this message because you are subscribed to
            the Google Groups "nhusers" group.
            To post to this group, send email to
            [email protected] <mailto:[email protected]>.
            To unsubscribe from this group, send email to
            [email protected]
            <mailto:nhusers%[email protected]>.
            For more options, visit this group at
            http://groups.google.com/group/nhusers?hl=en.




-- Fabio Maulo

-- You received this message because you are subscribed to the
        Google Groups "nhusers" group.
        To post to this group, send email to
        [email protected] <mailto:[email protected]>.
        To unsubscribe from this group, send email to
        [email protected]
        <mailto:[email protected]>.
        For more options, visit this group at
        http://groups.google.com/group/nhusers?hl=en.

-- You received this message because you are subscribed to the
        Google Groups "nhusers" group.
        To post to this group, send email to [email protected]
        <mailto:[email protected]>.
        To unsubscribe from this group, send email to
        [email protected]
        <mailto:nhusers%[email protected]>.
        For more options, visit this group at
        http://groups.google.com/group/nhusers?hl=en.




-- Fabio Maulo

-- You received this message because you are subscribed to the
    Google Groups "nhusers" group.
    To post to this group, send email to [email protected]
    <mailto:[email protected]>.
    To unsubscribe from this group, send email to
    [email protected]
    <mailto:[email protected]>.
    For more options, visit this group at
    http://groups.google.com/group/nhusers?hl=en.

-- You received this message because you are subscribed to the Google
    Groups "nhusers" group.
    To post to this group, send email to [email protected]
    <mailto:[email protected]>.
    To unsubscribe from this group, send email to
    [email protected]
    <mailto:nhusers%[email protected]>.
    For more options, visit this group at
    http://groups.google.com/group/nhusers?hl=en.




--
Fabio Maulo

--
You received this message because you are subscribed to the Google Groups "nhusers" 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/nhusers?hl=en.

--
You received this message because you are subscribed to the Google Groups 
"nhusers" 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/nhusers?hl=en.

Reply via email to