VisualStudioFeeds

All Visual Studio blogs in one place

AddThis Social Bookmark Button
I have often seen a recommendation that using DISTINCT instead of GROUP BY is better from a performance perspective. DISTINCT is definitely a more readable alternative, but I wanted to test for myself as to what the truth was. To compare the performance of the two, I wrote the following simple queries. The query below helps in identifying the number of records that SQL Server will need to process. On my machine, when executed without the GROUP BY or the DISTINCT clause, the query generates records in excess of 380,000.USE AdventureWorks2012; GO SELECT COUNT(so1.object_id) FROM sys.objects AS so1
CROSS JOIN sys.objects AS so2 ; GO The queries below fetch the same information – one uses the GROUP BY whereas the other query uses a DISTINCT.USE AdventureWorks2012; GO --Clean the buffers and procedure cache DBCC DROPCLEANBUFFERS; DBCC FREEPROCCACHE; GO --Evaluate GROUP BY SELECT so1.object_id, so1.name FROM sys.objects AS so1 CROSS JOIN sys.objects AS so2 GROUP BY so1.object_id, so1.name ; GO --Clean the buffers and procedure cache DBCC DROPCLEANBUFFERS; DBCC FREEPROCCACHE; GO --Evaluate DISTINCT SELECT DISTINCT so1.object_id, so1.name FROM ...(Read whole news on source site)

AddThis Social Bookmark Button
As many of you know, I am heading out on World Tour this June and heading across Europe and Asia for a year. For the first stop, I’ve partnered with Sparkles to do a training in Belgium this June. If you’re in Europe and you’ve been looking for a way to easily take my web development course, this is your opportunity. We’re only holding it once in Northern Europe. The course takes place from June 23-25th, 2014. If you’re in the area, this is a great opportunity to learn how to build
websites using the ASP.NET on the back-end and open source tools like Bootstrap 3 and AngularJS on the front-end. This course is a three-days, hands-on course that covers how to build web applications using the Microsoft’s ASP.NET stack including: ASP.NET MVC 5.1 ASP.NET Web API 2.1 Entity Framework Bootstrap 3 AngularJS The course walks you through starting a new project all the way through completing a web site. The course includes lecture, demonstration and hands-on lab. You will create your own website from scratch. You can see the outline of the course here: http://www.wilderminds.com/Training/Course/Authoring_Websites  To...(Read whole news on source site)

AddThis Social Bookmark Button
  If you are an ASP.NET dev and still wondering about Azure, the cloud offering from Microsoft, this is a presentation you don’t want to miss!!   “Top Azure features every ASP.NET developer should know about”
This meeting will be presented by Bill Wilder, MVP Azure from Boston, USA.   When: Monday, April 28, 2014
Where: Microsoft Montreal office (2000 McGill College, 4th floor, Montreal, QC)
Cost: Free for existing members, 5$ for visitors   To RSVP, visit

Search

Subscribe

Enter your email address:

Delivered by FeedBurner

Increase your website traffic with Attracta.com

Contact

Email:
Subject:
Message:
Anti-spam: How many eyes has a typical person?

Follow us on FB

Home