views:

271

answers:

1

Hello,

Quick question on LINQ to SQL generated queries output.

I am in a ASP.NET MVC project, Visual Studio 2008, and I am trying what's suggested in MSDN documentation:

MyDataContext _dc = new MyDataContext();
_dc.Log = Console.Out;

But nothing is being shown on "Output" window (CTRL+Alt+O).

Is there is something else I need to configure in order to make LINQ to SQL dumping debug info to Output window in Visual Studio 2008?

I don't know if it makes any difference, but my entities (and MyDataContext class) are located in a separate class library project.

+3  A: 

You can use LINQ to SQL Visualizer. Attach the debugger, add a breakpoint and you'll be able to use it.

Mehrdad Afshari