-->
SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 

Born SQL with Randolph West

Randolph West solves technology problems with a focus on SQL Server and C#. He is a Microsoft Data Platform MVP who has worked with SQL Server since the late 1990s. When not consulting, he can be seen acting on the stage and screen or doing voices for independent video games.

Why is a value in DATETIME2 8 bytes, but in BINARY it is 9 bytes?

In the #sqlhelp Slack channel on the SQL Server Community Slack workspace last month, Jemma Hooper asked: When trying to CAST or CONVERT a datetime2 value to binary(8), I’m getting a “binary or text data would be truncated” error. This seems really weird in context with the fact that SELECT… Read more

2 comments, 305 reads

Posted in Born SQL with Randolph West on 11 October 2017

Changes to Service Packs and Cumulative Updates for SQL Server 2017

For a few years now, Microsoft has augmented its irregular release of Service Packs with a more frequent Cumulative Update model, in order to get bug fixes and other improvements to customers faster. With SQL Server 2017, which runs on both Linux and Windows (as well as Docker containers for… Read more

0 comments, 301 reads

Posted in Born SQL with Randolph West on 4 October 2017

Compañero Conference and SQL Modernization Roadshow

October is a busy month for me. I am flying all over the US and Canada for speaking engagements to share some thoughts about migrating your SQL Server environment to the cloud (specifically Azure). Compañero Conference I will be presenting at the Compañero Conference, which takes place over two days,… Read more

0 comments, 211 reads

Posted in Born SQL with Randolph West on 27 September 2017

Does rebuilding my clustered index also rebuild my non-clustered indexes?

I’ve been working with SQL Server for many years now, and up until recently, I assumed that rebuilding any clustered index would cause non-clustered indexes to be rebuilt as well, because the non-clustered index includes the clustered index in it. This assumption is wrong. On SQL Server 2000, this only… Read more

0 comments, 267 reads

Posted in Born SQL with Randolph West on 20 September 2017

A trillion and one

Joe Obbish wrote an epic post a few weeks ago about loading a trillion rows into a non-partitioned table in SQL Server, using a clustered columnstore index to maximise the compression. (Short version: it’s very slow to query. Don’t do it. Bad things happen. I have an ongoing investigation with… Read more

0 comments, 325 reads

Posted in Born SQL with Randolph West on 13 September 2017

Connect Windows 10 client to a VPN on Windows Server 2012 R2

I got a strange request in a Slack channel the other day. A colleague in South Africa, who uses Windows, was unable to connect to our VPN (Virtual Private Network). We use the built-in VPN on Windows Server 2012 R2, which makes it extremely convenient to manage per-user security without… Read more

0 comments, 229 reads

Posted in Born SQL with Randolph West on 6 September 2017

What you need to know about memory limits on SQL Server

Last week, I posted this statement on Twitter, along with a screen capture of the official Microsoft documentation: Reminder: Max Server Memory is *not* just for the buffer pool. The RAM limit Standard Edition can use *is* just for the buffer pool. Joey D’Antoni was quick to remind me that… Read more

0 comments, 112 reads

Posted in Born SQL with Randolph West on 30 August 2017

Speaking at SQLSaturday #635 in Vancouver this weekend

This coming weekend, at SQLSaturday #635 in Vancouver BC, I will be presenting a brand new talk about Temporal Tables, one of my favourite features of SQL Server 2016+ and Azure SQL Database. If you are in the area, and still have not decided to attend, I strongly recommend making… Read more

0 comments, 54 reads

Posted in Born SQL with Randolph West on 23 August 2017

Microsoft presents: MySQL and PostgreSQL?

For the longest time, MySQL has been the recommended database platform for blogs and other websites. It’s free. It’s available on every version of Linux, which is the most common web server platform. If you need something more complex but still free, there’s PostgreSQL. But there’s a lot going on… Read more

0 comments, 63 reads

Posted in Born SQL with Randolph West on 16 August 2017

This is how I recovered from a catastrophic failure

I was fresh off the boat* from South Africa, working in a small computer store in an equally small town in Saskatchewan. Five days a week in winter, six days a week in summer, mainly removing malware from laptops, selling new computers (which is why I’m happy to recommend Asus… Read more

0 comments, 63 reads

Posted in Born SQL with Randolph West on 9 August 2017

Locks, Blocks, and Isolation Levels

Last week we looked at ACID compliance. This week we dive a little deeper into the Isolation portion, and what it all means. Isolation levels work to manage how my transactions may be isolated from your transactions, to allow concurrency. They work by locking sections of the database until a… Read more

0 comments, 60 reads

Posted in Born SQL with Randolph West on 2 August 2017

Acids and Databases: A look at ACID and transactions

Relational database management systems (RDBMS) such as SQL Server, Oracle, MySQL, and PostgreSQL use transactions to allow concurrent users to select, insert, update, and delete data without affecting everyone else. An RDBMS is considered ACID-compliant if it can guarantee data integrity during transactions under the following conditions: ACID Atomic –… Read more

0 comments, 54 reads

Posted in Born SQL with Randolph West on 26 July 2017

What is a good Disaster Recovery Plan?

During a Q&A session I hosted at our local Calgary SQL Server User Group last month, one of the attendees mentioned an interview question he’d had and wanted to hear my thoughts. How would you design a disaster recovery solution for a 1 TB database, using Simple Recovery Model? Replication… Read more

5 comments, 55 reads

Posted in Born SQL with Randolph West on 19 July 2017

Be Wary of Date Formatting in T-SQL

Today’s public service announcement is a reminder to be wary of date formatting in SQL Server. On a recent mailing list discussion, one person demonstrated the following code (which I’ve adapted for this post): SET LANGUAGE 'us_english'; GO DECLARE @StartDate DATETIME = '2017-07-12'; SELECT @StartDate; GO DECLARE @StartDate DATE =… Read more

2 comments, 53 reads

Posted in Born SQL with Randolph West on 12 July 2017

Balanced Power Saving T-SQL script

We can easily spend tens of thousands of dollars on core licences for SQL Server, and then we go and install the product on an operating system with the default Balanced Power Plan, which is, well, idiotic. Imagine buying one of the fastest road cars money can buy (a Bugatti… Read more

2 comments, 67 reads

Posted in Born SQL with Randolph West on 5 July 2017

Where To From Fundamentals?

The Database Fundamentals series is now done. We started with understanding what a database is, and then spent a little time understanding how databases store text, known as collation. The next step was understanding data types in general, and how SQL Server stores them. After that was understanding normalization, with… Read more

0 comments, 95 reads

Posted in Born SQL with Randolph West on 28 June 2017

Why You Need A Test Environment

In 2017, there’s no excuse not to have at least a testing environment, and preferably a development environment as well, in order to create and deploy code changes (software, database, you name it) outside of a production environment. If you’re making changes in a production environment without testing them first,… Read more

0 comments, 51 reads

Posted in Born SQL with Randolph West on 21 June 2017

How to write a DELETE query

My First DELETE Statement Here are the links to the previous posts in this series: My First SELECT Statement My First INSERT Statement My First UPDATE Statement This week is a much shorter post, where we will learn how to remove data from a table using a DELETE statement. We… Read more

2 comments, 49 reads

Posted in Born SQL with Randolph West on 14 June 2017

How to write an UPDATE query

My First UPDATE Statement Last week we covered how to put information into a table using an INSERT statement. This week we will learn how to make changes to data that is already in a table using an UPDATE statement. We are also going to learn all about why the… Read more

0 comments, 54 reads

Posted in Born SQL with Randolph West on 7 June 2017

How to write an INSERT query

My First INSERT Statement Last week we covered how to get information out of a table, using a SELECT query. This week, we will discover some of the myriad ways to put data into a table. The good news is the concept is straightforward: we have a list of columns… Read more

0 comments, 103 reads

Posted in Born SQL with Randolph West on 31 May 2017

Newer posts

Older posts