We are using Entity Framework Core 5 and ODP.NET. When seeding our database, we need to check around 1000 entities whether they are already in the database and whether they have to be modified. We load each dataset, modify it if neccessary, or create it in the database if neccessary. But after a few datasets we get the error:
Oracle.ManagedDataAccess.Client.OracleException (0x80004005): ORA-01000: maximum open cursors exceeded ORA-06512
We are aware what that error means and that we can increase the maximum number of open cursors. However, in the previous version of our application (which used the old Entity Framework 6 and DevArt Oracle Provider) it used to work.
What is causing the error in our new setup, ODP.NET or Entity Framework Core? And what can we do to avoid this error while seeding our database?