Home
Help
Register
Log in

Search

 
   Active Threads  

You are here: Home > LLBLGen Pro > Bugs & Issues> Refetch = false seems not to work on collections
 

Pages: 1
Bugs & Issues
Refetch = false seems not to work on collections
Page:1/1 

  Print all messages in this thread  
Poster Message
Meindert
User



Location:

Joined on:
07-Nov-2012 11:27:26
Posted:
63 posts
# Posted on: 06-Apr-2020 10:42:09.  
LLBLGen 5.1.1
DB: MSSQL

Hello,
I write to a view, the instead trigger of the view desides if a entity should be deleted. From de client view I have only new en dirty entities.

In case the entity is deleted by the view than I call adapter.SaveEntity(aEntity, false, false);
This works for a single entity.

To have better perfomance I like to use adapter.SaveEntityCollection(aEntityCollection, false, false);

When I call this function a got an exception:
ex = {"An exception was caught during the execution of an action query: ....}
  Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
38047 posts
# Posted on: 06-Apr-2020 12:11:57.  
Why omit the stacktrace? Regular Smiley A message like that is useless, sorry, like you know as a developer Wink . Give the full stacktrace, and also check whether some queries are generated/executed already or that it fails on the first query.

Refetch of the entity isn't done when the flag is false. SaveEntityCollection creates a unit of work and adds the collection to that with the flag specified (so false), and this flag is added to all workqueue items for the entities in the collection, and the flag in the workqueue item is then used to determine if the refetch should be taken after the insert.

I have the feeling the issue is caused by something else but without a stacktrace it's impossible to determine where to begin looking


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



Location:

Joined on:
07-Nov-2012 11:27:26
Posted:
63 posts
# Posted on: 06-Apr-2020 14:17:47.  
Sorry for the fuss, it turned out that the instead trigger was the problem.
  Top
Pages: 1  


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

Version: 2.1.12172008 Final.