Pulling this in reflector:
SessionImpl.Enumeration()
HQLQueryPlan.DoIterate
NHibernate.Hql.Classic.QueryTranslator.GetEnumerable()
What is currently returned is a true enumerable :-)
If I wanted to request this feature (enumeration for criteria & sql
query) which group would I need to post to?
The scenario I have where this would be super useful is:
http://groups.google.com/group/nhusers/browse_thread/thread/8ba75a088ae58d0e/2c9ca99ba33851da#2c9ca99ba33851da
Ajai
On Dec 13, 9:12 am, Fabio Maulo <[email protected]> wrote:
> If I well remember that impl. is only a mirage ;) (not a real enumerable
> where each row is converted only during enumeration).
>
> 2009/12/13 ajaishankar <[email protected]>
>
>
>
> > Thanks!
>
> > I think Enumeration is currently enabled for HQL queries; looking at
> > QueryTranslator & NHibernate.Impl.EnumerableImpl
>
> > Wouldn't the lazy-load Fabio explained affect that too?
>
> > Not trying to argue here - just getting an understanding...
>
> > Couldn't the burden of eager fetching be offloaded to the user since
> > enumerating might be a "specialized" usage?
>
> > Ajai
>
> > On Dec 13, 8:23 am, Jason Meckley <[email protected]> wrote:
> > > var objects = session.CreateCriteria().Add().List();
> > > foreach(var obj in objects)
> > > {
>
> > > }
>
> > > On Dec 12, 5:01 pm, ajaishankar <[email protected]> wrote:
>
> > > > I understand - but is there a particular reason for not enabling
> > > > enumerable over criteria or sql queries?
>
> > > > I feel the querying + data to object mapping capabilities combined
> > > > with streaming result behavior will be quite useful.
>
> > > > Unless I'm missing something, not being able to enumerate over the
> > > > results of a criteria seems to be an artificial restriction.
>
> > > > Ajai
>
> > > > On Dec 12, 2:12 pm, Jason Meckley <[email protected]> wrote:
>
> > > > > If you want ETL without SSIS look into Rhino.ETL (http://github.com/
> > > > > ayende/rhino-etl). NH is meant to be an ETL framework it's an ORM.
>
> > > > > On Dec 12, 11:57 am, ajaishankar <[email protected]> wrote:
>
> > > > > > Why isn't there a Enumerate for Criteria queries?
>
> > > > > > Also enumeration over a sql-query is currently not implemented!
>
> > > > > > I think it would be extremely useful to have these to enable ETL
> > kind
> > > > > > of processing using NH for large data sets.
>
> > > > > > That way we could use NH to build queries using detached criteria
> > and
> > > > > > do fancy SSIS kind of stuff like merge joins etc in code/Linq.
>
> > > > > > By enabling these we could have a good alternative to crappy
> > products
> > > > > > like SSIS...
>
> > > > > > Thanks
>
> > > > > > Ajai- Hide quoted text -
>
> > > > - Show quoted text -
>
> > --
>
> > 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]<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.