LessThanDot Site Logo

LessThanDot

A decade of helpful technical content

This is an archive of the posts published to LessThanDot from 2008 to 2018, over a decade of useful content. While we're no longer adding new content, we still receive a lot of visitors and wanted to make sure the content didn't disappear forever.

SELECT * vs SELECT 1 with EXISTS

Often, I see in articles and code a query using the EXISTS logical operator and a Subquery within the EXISTS using SELECT *. Typically this is an area where it’s been instilled in me to use SELECT 1 instead of SELECT * for performance reasons. However, is it a myth or is it reality that SELECT * vs. SELECT 1 will make an impact to performance when used in the EXISTS logical operator?

Read More...

Future, Career and Success – BlueMetal Architects

Every now and then, it’s important to sit back and reflect on what you’ve accomplished over time. Doing so can be an extremely effective motivator and professional development step to pushing yourself to accomplish more. Over the last few years, I’ve been fortunate to accomplish many really cool things and meet many milestones in my career. My involvement in the SQL Community is always a top accomplishment and I enjoy sharing with others the SQL Server and Professional Development skills I’ve gained.

Read More...

Removed Replication – rowguid added back

When replication features are used in a database, tables that are part of the publications may be altered. In particular, Merge and Transactional Replication require either a Primary Key or UNIQUEIDENTIFIER column in order to function correctly. In order to manage a change capture -not to be confused with Change Data Capture (CDC) – a unique value is required for every row in a table so replication knows what changes to replicate.

Read More...

VB.Net make one thread wait for the next now with Async Await

In my [previous post][1] I showed you how to use threads wait fro one another. But of course in VB11 we can also use Async Await out of the box. First of all let’s reproduce what we had with Async Await. I came up with this. I did not try this with lambdas (not even sure that would be possible for now). Imports System.Threading Module Module1 Sub Main() Method1() Method2() Console.

Read More...

VB.Net make one thread wait for the next

Yesterday we got a question on the VBIB.Be forum (dutch) about threading. The OP wanted to have one thread wait for the next. The problem with threading is that it is complicated. And that there a re more than one way to solve your problem. And the optimal solution highly depends on the specific problem at hand. The solution to his problem, have 1 thread wait on 1 other thread until the 1st thread is finished doing what it must be do, is pretty simple and straight forward.

Read More...

SSMS Add-in for Plan Explorer Update

It isn’t very often I’m left speechless at the efforts a company and team will go through to make their customers truly, 100% pleased with a product. Tonight was one of those times. Yesterday, October 15th, I published a review of the new Plan Explorer Pro from SQL Sentry, “Plan Explorer Pro – First Glance”. I already take every chance I get to show off Plan Explorer and relay the value it holds to both, DBAs and Developers.

Read More...

Plan Explorer Pro – First Glance

Over these past few days, I’ve had a chance to check out the new release of Plan Explorer Pro from SQL Sentry. I’d like to thank them again, for giving me the chance to dig into this new edition and make full use of the additional features it has to offer. As with any software, there are pros and cons to what you can do with it. Let’s face it, not everyone can be fully satisfied 100% of the time.

Read More...

Ncrunch goes commercial

I’ve been using the beta of NCrunch for a while now and have been pretty happy with it. It has been “free” up until now. But the time has come for the developer of this product to make some money out of this. And we can only applaud that. Giving away things for free is one thing but it won’t last. We are not yet in the ideal universe Star Trek wants us to believe is coming in the future.

Read More...

Why does sys.dm_exec_requests not show my SPID?

This morning, like many other mornings, I ran sys.dm_exec_requests to check for an open transaction. This was due to an application faulting and leaving an update in an uncommitted state. Ignoring the concept of why this happened and the transaction isn’t rolled back as typical when a connection is forcibly closed, sys.dm_exec_requests, introduced with the new metadata in SQL Server 2005, is usually the first DMV I run. Usually, after I run the DMV, I yell at myself and go to others.

Read More...

Another obscure difference between C# and VB.Net you probably don’t know about

I heard about this one on twitter from David Tchepak the author of NSubstitute. He referred to a question they got on the Google groups for NSubstitute. The question is this. 1/ Create a new empty project (console application is ok) 2/ Add a single line in Main: Dim x As Castle.DynamicProxy.IProxyTargetAccessor Obviously this don’t compiles. 3/ Install NuGet package of Castle Windsor (3.1.0) Now, previous code line already compiles.

Read More...