Pages

Monday, October 11, 2010

SQL Server 2008 R2 DACPAC Bug - Cannot insert the value NULL into column 'created_by', table 'msdb.dbo.sysdac_instances_internal'


While trying out the new DACPAC feature in SQL Server 2008 R2 recently, I ran into a bug that makes no sense to me at all.  In my environment we use an Active Directory Group for the SQL Database Administrators and that group is a member of the sysadmins...(read more)
Source: sqlblog.com

SQLBits 7 Wrap Up
Last week I was in Great Britain for SQL Bits 7.  This was the first conference outside of the United States that I have attended, and I was honored to attend SQL Bits 7 as a speaker during Friday’s Sessions.  The city of York is absolutely...(read more)
Source: sqlblog.com

Scripting Database Mail Configuration with Powershell and SMO
Setting up Database Mail in SQL Server 2005 and 2008 is a common task that is performed post server setup. However, if you just took over a fairly large environment and faced having to configure Database Mail on dozens, maybe hundreds of servers, SQL...(read more)
Source: sqlblog.com

Join the UK SQL Usergroup – See Tony in wellies and Hawaiian shirt
Tony Rogerson who co-ordinates the UK SQL Usergroup has set a challenge. If we can get the number of members for the UK SQL Usergroup LinkedIn group to 1000 by the time of SQLBits. He’ll present in wellies and a Hawaiian shirt. So get joining the linkedIn...(read more)
Source: feedproxy.google.com

New training session for SQLBits
After some thought we’ve decided to change Buck Woody’s training day session. Instead of doing a full day on career development he will be doing a session on SQL Server for the Non DBA. This is a great session for anyone that has been thrown into running...(read more)
Source: feedproxy.google.com

Dates don’t work when copied from SQL Profiler - Error converting data type varchar to datetime
If you are running with British english as your language or some other language with a different date format to the guys in the US then you will have come across this handy error. Msg 8114, Level 16, State 5, Procedure foo, Line 0 Error converting data...(read more)
Source: feedproxy.google.com

Last minute availability for SQLBits Training Days
Due to a cancellation there is some last minute availability on Chris Webb’s Performance Tuning Analysis Services and Chris Testa-Oneil’s Implementing Reporting Services training days. If you haven’t registered for a training day then register quick as...(read more)
Source: feedproxy.google.com

T-SQL Tuesday #008: Turning Civilians into Soldiers
          This month’s T-SQL Tuesday, started by Adam Machanic ( Blog | Twitter ),  is being put on by SQLServerCentral author and MCM, Robert Davis ( Blog | Twitter ).  This month the topic is learning and teaching...(read more)
Source: sqlblog.com

SQL Null: a set of posts on the null
Null is a special marker used in Structured Query Language (SQL) to indicate that a data value does not exist in the database. Introduced by the creator of the relational database model, E. F. Codd, SQL Null serves to fulfill the requirement that all true relational database management systems (RDBMS) support a representation of "missing information and inapplicable information". Codd also introduced the use of the lowercase Greek omega (ω) symbol to represent Null in database theory. NULL is also an SQL reserved keyword used to identify the Null special marker. Null has been the focus of controversy and a source of debate because of its associated three-valued logic (3VL), special requirements for its use in SQL joins, and the special handling required by aggregate functions and SQL grouping operators. Although special functions and predicates are provided to properly handle Nulls, opponents feel that resolving these issues introduces unnecessary complexity and inconsistency into the relational model of databases. Since Null is not a member of any data domain, it is not considered a "value", but rather a marker (or placeholder) indicating the absence of value. Because of this, comparisons with Null can never result in either True or False, but always in a third logical result, Unknown. In my next few posts, I will explore the null.
Source: brian.chipsofttech.com

Working with the SQL Server Powershell Provider and Central Management Servers from Powershell
I am a big fan of the Central Management Server setup that exists in SQL Server 2008, as well as how you can leverage this for the Enterprise Policy Management Framework that Laura Rubbelke ( Blog | Twitter ) created on Codeplex.  Today one of my...(read more)
Source: sqlblog.com

SQL Null: Grouping and sorting
Because SQL Server defines all Null markers as being unequal to one another, a special definition was required in order to group by Nulls together when performing certain operations.  SQL defines “any two values that are equal to one another, or any two Nulls”, as “not distinct”.  This definition of not distinct allows SQL to group and sort Nulls when the “GROUP BY” clause are used.  Let’s look at an example using group by and nulls.  You will see, that SQL Server does group them together by using the not distinct definition: DECLARE @table1 TABLE( ID INT, myStr VARCHAR(100)) INSERT INTO @table1( ID, myStr) Values (1, 'value a'), (2, 'value b'), (3, 'value a'), (4, 'value a'), (5, 'value b'), (6, null), (7, 'value b'), (8, null), (9, null), (10, 'value a'), (11, null), (12, null) SELECT * FROM @table1 SELECT myStr,       COUNT(1) as CountFROM   @table1GROUP  BY myStr The 1st select results show the raw values: ID myStr 1 value a 2 value b 3 value a 4 value a 5 value b 6 NULL 7 value b 8 NULL 9 NULL 10 value a 11 NULL 12 NULL The 2nd results show the group by: myStr Count NULL 5 value a 4 value b 3 As you can see, when SQL Server completes the group by clause it combines rows with NULL values.  When thinking about how it handles string concatenations, this is a little twist that can catch you off guard or make you think.  Distinct, same thing: SELECT distinct myStr FROM @table1 The result is 3 rows: NULL, value a, value b Hope this helps you when thinking about null values and grouping.  Try the example and look how SQL Server handles the default sort order for Nulls.
Source: brian.chipsofttech.com

There is no such thing as a “Small Change” to a production database
It seems like every week I get hit up with some kind of “Its a view only for this specific report,” or “It is a simple change that the vendor would have made if they had access” type of request related to SQL Server.  If you’ve never dealt with me,...(read more)
Source: sqlblog.com

20 MVPs and 4 former MVPs at SQLBits
I thought I’d have a little count up and I’ve found that over almost 50% of the sessions will be delivered by current or former SQL MVPs . How awesome is that. Whats great is that we have MVPs from all over the world attending SQLBits. Which goes to show...(read more)
Source: feedproxy.google.com

Only a few places left for the SQLBits training days
All the training day sessions for SQLBits 7 are really popular which means there are only a few places left on each of them. I know lots of people that are thinking of going to the training day and haven’t booked yet. if you are one of them make sure...(read more)
Source: feedproxy.google.com

Bug in SQL 2008: Why you shouldn’t create large tables in the Model Database
If you follow me on Twitter ( @SQLSarg ) you probably saw tweets about a bug I encountered in SQL Server 2008 recently.  What was hoped to be a normal Monday morning started off with alerts from a new production server that DBCC CHECKDB had failed...(read more)
Source: sqlblog.com

No comments:

Post a Comment