Hi
i have an array which is a shopcart with x number of items when the user checks out of the cart i want to insert the cart items into a table called basket and the totals of the shopcart items into a table called baskethdr.
i need all record to be inserted on rollbacked if fail. In examples shown in the step by step we are adding 1 by 1 item but that is not how i need. please can you assist me here.
my
3 Answer(s)
-
0
Hi,
Even if you add records one by one, they all will be rolled back. Of course this is valid for UnitOfWork methods. If you do it in App Service or Controller, this will be done automatically.
But if you want to insert batch records, this is another topic and ABP/AspNet Zero does not support it by default, you can use a third part tool for this.
Thanks.
-
0
which is the tool , also can you please explain what you mean by
Even if you add records one by one, they all will be rolled back. Of course this is valid for UnitOfWork methods. If you do it in App Service or Controller, this will be done automatically.
regards
anwar
-
0
Hi @avanekar02,
which is the tool , also can you please explain what you mean by
Actually we don't offer any tool for batch database operations, you can search it by yourself.
If you want to do it by ABP and AspNet Zero, you need to insert records one by one.
Thanks.