Linqpad lets you query Entity Framework models that you define in Visual Studio. In a nutshell, here's how to proceed:
- CreateADO. NET Entity Data ModelIn a Visual Studio project, and build.
- From linqpad, clickAdd connection(Top left)
- SetData ContextDropdownCustom Entity Framework objectcontext:
- ClickBrowseAnd locate the Assembly (DLL or EXE) that you built in Step 1:
- Choose your typed objectcontext class and Entity Data Model:
- ConfirmSQL ServerAndDatabaseDetails and click OK.
- Your conceptual model will now show in the schema explorer. Right-click to start a new query:
A few notes:
- You can return to Visual Studio at any time and rebuild-linqpad will not lock your assembly.
- Linqpad automatically refreshes the schema explorer and autocompletion cache whenever the Assembly changes.
- If your Assembly references other assemblies, linqpad will pick up these, too, providing they live inSame folder.
Http://www.linqpad.net/EntityFramework.aspx