Breaking news from around the world
Get the Bing + MSN extension
Now Available in Community - MBAS 2019 Presentation Videos
Catch the most popular sessions on demand and learn how Dynamics 365, Power BI, PowerApps, Microsoft Flow, and Excel are powering major transformations around the globe. | View Gallery
2019 release wave 2 Discover the latest updates to Dynamics 365Release overview guides and videos Release Plan | Early Access Availability
Ace your Dynamics 365 deployment with packaged services delivered by expert consultants. | Explore service offerings
Connect with the ISV success team on the latest roadmap, developer tool for AppSource certification, and ISV community engagements | ISV self-service portal
The FastTrack program is designed to help you accelerate your Dynamics 365 deployment with confidence.
FastTrack Program | Finance TechTalks | Customer Engagement TechTalks | Talent TechTalks | Upcoming TechTalks
I am pleased to announce that we released “LINQPad 4 Drive for Dynamics CRM” on CodePlex.
LINQPad (http://www.linqpad.net/) is a great tool which you can write and execute LINQ query against many data sources, like SQL Server, Oracle or Web Services. In addition to LINQ query support, the tool also supports C#/F#/VB expression, statement block or program, to write and execute the code and code snippet.
What can you do with CRM Driver?
By using CRM Driver, you are able to run LINQ query against Microsoft Dynamics CRM organizations on the fly. Follow the steps below to try it out!
Install Driver to LINQPad
1. Download and install LINQPad if you don’t have it yet from http://www.linqpad.net/.
2. Go to https://linqpaddriverforcrm.codeplex.com/ and click “DOWNLOADS” tab, then download CRMLinqPadDriver.lpx file.
3. Open LINQPad and click “Add connection” link on top left.
4. Click “View more drivers…” button at the bottom of the page.
5. Click “Browse” button in the bottom of the page.
6. Select downloaded CRMLinqPadDriver.lpx file, then click “Open”.
7. Click OK.
Use the Driver
1. Select “Dynamics CRM Linq Pad Driver” in Choose Data Context and click “Next”.
2. Click “Login to CRM” button.
3. Login to your Organization at login screen.
4. Then it automatically start loading metadata and DataContext from selected organization. Wait until it’s done.
5. Once “Loading Data” completed, click “Exit”. Then LinqPad starts loading schema, which takes a bit of time. Wait until you see schema information on the left pane like below screenshot.
Write LINQ query and Execute
1. Firstly, select added connection from “Connection” dropdown on the top right.
2. Enter following query to query window.
3. Click “Play” button or press F5 key to execute query. You will see the result in result pane.
4. Click SQL tab in result pane, where you can find QueryExpression and FetchXML equivalent to LINQ query.
Write C# statement and Execute
In addition to LINQ query, you can write C# as well.
1. Click [+] tab to open new query window next to existing Query tab.
2. Select “Connection” again.
3. Select “C# Statement(s)” from Language dropdown.
4. Enter following statements and Execute.
“this” of above statement represents DataContext of your connection, which is CrmOrganizationServiceContext. Therefore “this” has all common method from OrganizationService, as well as methods from OrganizationServiceContext.
When you use free version of LINQPad, you won’t get IntelliSense, but if you purchase the license, it works like Visual Studio.
We would like to hear feedback from you!! As it’s open source, you are able to extend it to your own needs, or you can suggest/report bugs.
Ken Premier Mission Critical/Premier Field Engineer Microsoft Japan
Business Applications communities