Trace SQL Command Execution with .NET EF Core

Trace SQL Command Execution with .NET EF Core

Postby palmi » Wed 01 Mar 2017 19:41

Hi Support,

I was wondering if there is a way to use the second optional parameter of the UseOracle() method for ASP .NET Core (Action<OracleDbContextOptionsBuilder>) to trace and log each executed SQL command?
I haven't found any example how to accomplish this.

Thank you
palmi
 
Posts: 13
Joined: Thu 16 Feb 2017 16:52

Re: Trace SQL Command Execution with .NET EF Core

Postby Shalex » Mon 06 Mar 2017 14:40

There are two ways for logging SQL statements:
1) EF Core specific -> https://docs.microsoft.com/en-us/ef/core/miscellaneous/logging
2) provider specific -> https://www.devart.com/dotconnect/oracle/docs/?dbmonitor.html
Shalex
Devart Team
 
Posts: 7530
Joined: Thu 14 Aug 2008 12:44


Return to dotConnect for Oracle