Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 

SQL Server 2012 FileTable – Part 1

In a series of blog posts we will have a look at the new SQL Server 2012 table type called FileTable. This first blog post will be a simple getting started – how to create a FileTable and how to dump files into the folder and do some simple file… Read more

10 comments, 3,052 reads

Posted in SQL Server Notes from the Field on 3 January 2012

Danish Developer Conference – DDC 2012

I am proud to announce that we at Geniiius will be speaking at DDC 2012. DDC 2012 is a one day event held in Horsens, Denmark on the 29th of February 2012. You can sign up for the conference by following this link.

DDC 2012 is all about… Read more

0 comments, 743 reads

Posted in SQL Server Notes from the Field on 29 December 2011

SQL Server 2012 – new conversion functions

With SQL Server 2012 comes a new set of conversion functions, that will certainly help doing type casts and conversions in t-sql. These functions are:

TRY_PARSE()

Syntax from BOL:

TRY_PARSE ( string_value AS data_type [ USING culture ] )

This function works similar to the well… Read more

1 comments, 681 reads

Posted in SQL Server Notes from the Field on 20 December 2011

SQL server 2012 Startup parameters

I’m sure that I’m not the only one with nightmares about the startup parameters in older versions of SQL Server 200x – the design and UI is just bad, it is so easy to forget a semicolon or mess up the syntax – and to end up with SQL Server… Read more

0 comments, 511 reads

Posted in SQL Server Notes from the Field on 6 December 2011

CONCAT() – SQL Server 2012

With SQL Server 2012 a new string function is born – CONCAT(). The output is a string, as the result of the concatenation of two or more strings – if the input is another type than string a conversion will be done implicit. The CONCAT() function takes between 2 and… Read more

2 comments, 566 reads

Posted in SQL Server Notes from the Field on 29 November 2011

SQL Server trace flags

Normally I’m not a big fan of using traceflags, my advice is only to use these when it is absolutely necessary otherwise don’t. Here is a list of the documented traceflags that you can use with SQL Server. That is the documented once, besides that there is a list of… Read more

1 comments, 978 reads

Posted in SQL Server Notes from the Field on 22 November 2011

SQL Server ® 2012 Release Candidate (RC0)

Finally it is here, the SQL Server 2012 RC0 is ready for download, click this link and you’ll be downloading the good stuff in seconds. While you are downloading, you might want to have a look at some of these links, to read the official Microsoft information on what’s new… Read more

0 comments, 373 reads

Posted in SQL Server Notes from the Field on 18 November 2011

SQL Server 2012 licensing

Microsoft has recently released the licensing overview for SQL Server 2012. A few things has changes from SQL Server 2008, and I will just give a brief overview over these changes.

CPU vs core

The first major change in my opinion is the change from CPU socket licensing to… Read more

0 comments, 630 reads

Posted in SQL Server Notes from the Field on 14 November 2011

How much space are you wasting?

A few weeks back a client of mine asked me to write a script that could tell him the space used by write only indexes. The usage stats from the indexes is pretty easy to get from ‘sys.dm_db_index_usage_stats’ and if you join the DMV ‘sys.dm_db_partition_stats’ onto… Read more

2 comments, 422 reads

Posted in SQL Server Notes from the Field on 8 November 2011

Backup/restore/checkdb/shrinkfile progress

Have you ever wonderet how long you need to wait for a backup or restore command to complete? If you perform the backup or restore from the gui in management studio, it shows you the progres for every 10%. But what to do if you issuet the backup or restore… Read more

0 comments, 639 reads

Posted in SQL Server Notes from the Field on 1 November 2011

Multiple query plans for the same query?

A while back i was creating a stored procedure to be used for pulling data from the SQL Server into cacti. The procedure was pulling data from a rather large table, which I had made sure was indexed properly for my query. When I executed the stored procedure from… Read more

9 comments, 4,718 reads

Posted in SQL Server Notes from the Field on 25 October 2011

When was SQL Server restarted?

One of the main goals with this blog is to write stuff when we learn / discover new things or smarter and more efficient ways to do things – and that is spot on what I’ll do today.

Finding the time when SQL Server was last restarted, and using that… Read more

0 comments, 1,097 reads

Posted in SQL Server Notes from the Field on 18 October 2011

Dude, Where is my memory?

We all know that SQL Server loves memory, and in my opinion SQL Server can never have to much RAM. RAM is faster and cheaper than IO capacity and RAM can reduce the pressure on the IO sub system.

Let’s see if we can write some diagnostic queries that can… Read more

0 comments, 373 reads

Posted in SQL Server Notes from the Field on 11 October 2011

Index usage

Last week I blogged about how to get help identifying possible missing indexes by using some of the DMV’s provided by SQL Server. This week I will show another one that can be used to see how often a given index has been used.

The DMV is this one:

select…

Read more

0 comments, 535 reads

Posted in SQL Server Notes from the Field on 4 October 2011

Missing indexes

One of the most common things I encounter when asked to help with performance problems, is wrong or inadequate indexing. Creating the optimal indexes for a system, is no where near a trivial excercise. You need to consider the read/write ratio as well as how you write your queries. This… Read more

0 comments, 647 reads

Posted in SQL Server Notes from the Field on 27 September 2011

How to monitor number of VLF’s in your database

A few weeks back we did a blog post about a file grow bug that has been fixed with SQL Server Denali (Autogrow bug – fixed with Denali). The same blog posted explained why it is important not to have millions of VLF’s (Virtual Log Files). The method… Read more

0 comments, 829 reads

Posted in SQL Server Notes from the Field on 20 September 2011

T-SQL Function: EOMONTH

We have all been in a situation where we had to get the last day of the month with T-SQL. The world would just be so much easier with 30 days in every month, which is not the case. To calculate if the last day is 31, 30, 28 or… Read more

9 comments, 2,333 reads

Posted in SQL Server Notes from the Field on 13 September 2011

Blog Series: T-SQL Enhancements

Three months back in this blog post – T-SQL Enhancements in SQL Server Denali (2011) – we promised to do a series of blog posts, focusing on some of the new T-SQL enhancements that we all are looking forward to in SQL Server Denali.

This is not a post to… Read more

0 comments, 609 reads

Posted in SQL Server Notes from the Field on 6 September 2011

New LOGICAL functions in SQL Server Denali

IFF Function

If you are an old Access or Excel “developer” you know this one. This is not a function I have been missing before I read about it today. If you, like me, is so tired of writing CASE statements with only 2 possible outcoms – you will love… Read more

20 comments, 1,449 reads

Posted in SQL Server Notes from the Field on 6 September 2011

T-SQL Enhancements: FIRST_VALUE() and LAST_VALUE()

A couple a weeks ago I blogged about a few of the enhancements in the OVER clause, and now I will show you guys a couple of new windowing functions, that goes along with the OVER clause. These new functions are FIRST_VALUE() and LAST_VALUE().

I’ll use the same setup… Read more

6 comments, 2,434 reads

Posted in SQL Server Notes from the Field on 30 August 2011

Newer posts

Older posts