Home
Help
Register
Log in

Search

 
   Active Threads  

You are here: Home > LLBLGen Pro > Bugs & Issues> Turn off polymorphic fetch for performance reasons
 

Pages: 1
Bugs & Issues
Turn off polymorphic fetch for performance reasons
Page:1/1 

  Print all messages in this thread  
Poster Message
hotchill
User



Location:
Stavanger, Norway
Joined on:
22-Jan-2007 12:29:46
Posted:
156 posts
# Posted on: 05-Sep-2019 11:12:07.  
Hei.

We are using LLBLGen v5.6.0 RTM, adapter.

I am using FetchEntityCollection, including only fields from the super-most table of a hierarchy. I still get joins to all sub tables which is bad for performance.

I'd like to turn off polymorphic for my fetch. Is that possible?

If not, Linq is an option, but we have a lot of UI filter and sort event handling that needs rewriting.

So perhaps typed list is the best approach?


Thanks,
Tore.
Tore Olav Kristiansen
Lead Developer, IdentityStream
 
Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
37476 posts
# Posted on: 05-Sep-2019 16:11:48.  
If you need the data of the root entity only, it's perhaps also an idea to map an entity onto that table separately of the hierarchy and use that entity for your fetch for this particular situation (if you need to modify the data).

If you need the data in a readonly fashion, you can indeed also map a typed view with a poco query (linq or queryspec) onto the table, which doesn't bring in the derived types when querying it.


Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
hotchill
User



Location:
Stavanger, Norway
Joined on:
22-Jan-2007 12:29:46
Posted:
156 posts
# Posted on: 05-Sep-2019 22:25:34.  
Thanks Frans.

Good tip. I will proceed with mapping another entity on the table.

Please consider this a feature request though. It would be a lot simpler with a flag to turn off polymorphic fetch.
Tore Olav Kristiansen
Lead Developer, IdentityStream
 
Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
37476 posts
# Posted on: 06-Sep-2019 09:12:50.  
Ok, like a linqQuery.NoSubtypes() method? We'll see what we can do.

Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
hotchill
User



Location:
Stavanger, Norway
Joined on:
22-Jan-2007 12:29:46
Posted:
156 posts
# Posted on: 06-Sep-2019 09:40:23.  
I was thinking a noSubTypes flag to the FetchEntityCollection method.
Tore Olav Kristiansen
Lead Developer, IdentityStream
 
Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
37476 posts
# Posted on: 07-Sep-2019 10:17:06.  
Yes in queryspec it will likely be that or a method on the query. Flags on the fetch methods are a bit problematic as they add a set of overloads.

Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
Pages: 1  


Powered by HnD ©2002-2007 Solutions Design
HnD uses LLBLGen Pro

Version: 2.1.12172008 Final.