-->
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.

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, 150 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, 216 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, 146 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, 22 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, 14 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, 15 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, 13 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, 15 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, 14 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, 15 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, 14 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, 16 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, 18 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, 13 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, 15 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, 14 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, 19 reads

Posted in Born SQL with Randolph West on 31 May 2017

How to write a SELECT query

My First SELECT Statement Microsoft SQL Server makes it really easy for us to query tables. In SQL Server Management Studio (SSMS) for instance, we can right-click on any table we have access to and select the top 1000 rows from that table. Please don’t query tables this way in… Read more

2 comments, 14 reads

Posted in Born SQL with Randolph West on 24 May 2017

Querying a Database

When we want to retrieve information from a database, we query the structure with language appropriate to the database. Remember right at the start of this series we saw that a database could be a phone book or a recipe book. So how do we find the phone number of… Read more

0 comments, 14 reads

Posted in Born SQL with Randolph West on 17 May 2017

SQL Server Management Studio v17.0

Version numbers are confusing. SQL Server Management Studio (SSMS), the client user interface by which most DBAs access SQL Server, was decoupled from the server product for SQL Server 2016. For the last 18 months or so, we have been receiving semi-regular updates to SSMS (which we can download from… Read more

0 comments, 23 reads

Posted in Born SQL with Randolph West on 10 May 2017

Older posts