Is there a way to see the final query that is being transferred to the SQL Server database from my C # application?
For ex, I received a request:
SELECT * FROM mytable WHERE x = @yyyy;
This creates an SQLCommand object.
SqlCommand cmd = new SqlCommand("SELECT * FROM mytable WHERE x = @yyyy");
Plus I need to pass a parameter:
cmd.Parameters.Add("@yyyy","MyValue");
What I want to see (in debugging in C # or somewhere in SQL Server Management Studio) is the following:
SELECT * FROM mytable WHERE x = MyValue
Where can I find such a request ?!
Best wishes
source share