in

SQL Server Blogs

Voices from the UK SQL Server Community

Browse by Tags

  • User defined function performance is awful, Micorosft please sort this out

    User defined functions looked like something great when they were introduced in SQL 2005. They are a very logical step to make more code reuseable by wrapping common code in functions. It is an approach that is in development 101 and something everyone does and looks to doing. So what is the problem...
    Posted to Simons SQL Blog (Weblog) by simonsabin on Thu, Jan 14 2010
  • Enforcing parent child relationship with Path Hierarchy model

    With the classic adjacency model its dead easy to validate that a parent exists, its a bit more difficult with path model. The adjacency model you have a table with a self join you can easily add a foreign key between the two columns. When you store a path the difficulty is that you don't have anything...
    Posted to Simons SQL Blog (Weblog) by simonsabin on Mon, Mar 9 2009
  • TSQL Scalar functions are evil.

    I’ve been working with a number of clients recently who all have suffered at the hands of TSQL Scalar functions. Scalar functions were introduced in SQL 2000 as a means to wrap logic so we benefit from code reuse and simplify our queries. Who would be daft enough not to think this was a good idea. I...
    Posted to Simons SQL Blog (Weblog) by simonsabin on Mon, Nov 3 2008
  • System function to return just the date and no time

    You will notice a DATE related theme of the posts today. This one is about the lack of a system function that returns JUST the date and DOESNT include any tiem component. Due to time constraints they didn't include such a function, seems like a car without a steerwheel to me, but time is time and...
    Posted to Simons SQL Blog (Weblog) by simonsabin on Tue, Oct 28 2008
  • SQL Server 2008 - Whats this abut 30,000 columns?

    Its all about Sparse columns and they are a great feature of Katmai Imagine you have a products table, you will have attributes for some products that don't apply to others i.e. cup size applies to bras but not to socks. There are a number of ways of modelling this each with downsides. With sparse...
    Posted to Simons SQL Blog (Weblog) by simonsabin on Sun, Mar 16 2008
  • SQL Server 2008 - Converting binary(hex) values to strings

    One of the frequently asked questions in the newsgroups is how do you convert a string representation of a binary value to the equivalent binary value and the reverse. The latter is often required to be able to print out the binary representation. There have been a few undocumented functions and many...
    Posted to Simons SQL Blog (Weblog) by simonsabin on Tue, Mar 11 2008
  • SQL Server 2008 - ISDATE doesn't work with

    I really don't understand this. The ISDATE function doesn't work with new date and time types, whats more you can't pass it a string representing a date before 1/1/1753. Try this select ISDATE('1/1/1700') in SQL 2008 it will return 0. Whats odd is that there is no function to cater...
    Posted to Simons SQL Blog (Weblog) by simonsabin on Wed, Mar 5 2008
  • SQL Server 2008 Plan Guides from Cache

    Uhoh... I can see some junior developers going crazy with this. One of the things that kept plan guides from being over used was the fact that they are kind of hard :) Well, Microsoft built their empire making hard stuff easy. They do it again with sp_create_plan_guide_from_cache. Let's look at this...
    Posted to Jason Massie's SQL blog (Weblog) by JasonMassie on Fri, Jan 18 2008
  • SQL Server 2008 - Batch inserts and identity columns using MERGE

    Performing bulk inserts into a table when the table has an identity column has long bee a difficult challenge for client programming. The difficulty has been getting the identity values that have been generated for the set of data you are saving. It becomes even more difficult when you want to save parent...
    Posted to Simons SQL Blog (Weblog) by simonsabin on Mon, Dec 31 2007
  • Katmai Spatial - First thoughts

    I've been doing some work with the Spatial types in Katmai and these are my first thoughts. The first thing is that the data type is the same used by SQL as used in your .Net code. So what does that mean, · You use the same methods, which is great from a familiarity perspective · When calling the...
    Posted to Simons SQL Blog (Weblog) by simonsabin on Sun, Dec 9 2007
Page 1 of 2 (11 items) 1 2 Next >
Powered by Community Server (Commercial Edition), by Telligent Systems