XKCD can be variable in quality (or maybe I just don’t understand all the jokes), but it has this cautionary tale about Linux:

I’ve just had the email through to let me know that my session has been selected for SQL Bits III on the 13th of September. I’ll be talking on the subject of Spatial Queries in SQL Server 2008, an evolving talk I’ve done a couple of times before. It will be updated once again for SQL Bits III.
Here’s the abstract: It is reckoned that 80-90% of data has a spatial component to it. But what do we do with it now? At best, we constrain it to postcodes. Well, that would be great if we were delivering letters, but the majority of us aren’t. In this session we look at Spatial Queries in SQL Server to see how it works and what can be done with it.
Finally, Microsoft have a date for an event in Scotland. It is on 16th of October in their new offices in Waverley Gate, Edinburgh. Here are the details:
16 October 2008 13:30 – 16:15
Welcome Time: 13:00
Microsoft Scotland
Waverley Gate
2-4 Waterloo Place
Edinburgh EH1 3EG
Event Overview
Timings
13.00 for 13.30 Registration
13.30 – 14.45 Session 1
14.45 – 15.00 break
15.00 -16.15 Session 2
16.15 close
Overview:
“Service Pack? We’re calling it a Service Pack? Are you kidding??!?!”
Visual Studio 2008 Service Pack 1 will release later in 2008 alongside .NET Framework V3.5 Service Pack 1 and, together, they represent a significant upgrade to Visual Studio 2008. There are enhancements across many areas of the .NET Framework such as data access, windows application development and web development and there are also corresponding changes in the development environment to support the new framework features.
Session 1: What’s New for Web & Windows Development?
Here we’ll explore the changes to web and windows development with Service Pack 1. In the web space, we’ll take a look at the new controls added to ASP.NET for easy playback of media and Silverlight content and we’ll take a good look at the new Dynamic Data framework for quick “scaffolding” of a web site. In the Windows world, we’ll look at the new capabilities of Windows Presentation Foundation V3.5 Sp1 and the new, smaller, subset of the .NET Framework in the .NET Client Profile that makes deployment of WPF applications much easier.
Session 2: What’s New for Data?
The ADO.NET team have been busy for Service Pack 1 of Visual Studio 2008. There are two major new pieces of functionality – the ADO.NET Entity Framework provides a level of abstraction over your data store with a LINQ-enabled, object-relational-mapping API. The other new piece of functionality, ADO.NET Data Services easily exposes arbitrary data over a RESTful set of web services. In this session, we’ll explore both to give you an idea of what’s happening in data access. We’ll also make a brief mention of the changes around SQL Server 2008 data types and tooling.
Speaker Biogragphy:
Mike Taulty
Mike Taulty, Microsoft: Mike has been in the team since 2003 and is currently looking at technologies such as Visual Studio 2008 Service Pack 1, Silverlight V2 and SQL Server 2008. Before joining the Community team, Mike worked in Microsoft’s Services group as a developer consultant focused on helping ISVs and Enterprises develop their applications. Prior to joining Microsoft, Mike spent the previous nine years working as a software developer for a number of different software houses, end-users and consultancies, making use of various operating systems, databases and what used to be called ‘middleware’.
Eric Nelson
After many years of developing on UNIX/RDBMS (and being able to get mortgages) Eric joined Microsoft in 1996 as a Technical Evangelist (and stopped being able to get mortgages due to his new ‘unusual job title’ in the words of his bank manager). He has spent most of his time working with ISVs to help them architect solutions which make use of the latest Microsoft technologies – from the beta of ASP 1.0 through to ASP.NET, from MTS to WCF/WF and from the beta of SQL Server 6.5 through to SQL Server 2008. Along the way he has met lots of smart and fun developers – and been completely stumped by many of their questions!
In July 2008 he switched role from an Application Architect to a Developer Evangelist in the Developer and Platform Group. Currently Eric’s interests include digging into LINQ to Entities, ADO.NET Data Services and switching from C# to Visual Basic development.
At home, he battles rat infestations, comes second to the family dog and uses any spare moments he has after 10pm to team up and play online with and against friends – keep an eye out for ‘erknel’ and say ‘hi’
I’ve visited the SysInternals site a few times over the course of my career because of some strange problem that I just couldn’t track down. The amount of information about what is actually happening on your system that the SysInternals tools provide is phenomenal. The site was run by Mark Russinovich and Bryce Cogswell until they got hired by Microsoft. However, the tools are still available and being updated, only now they are hosted by Microsoft themselves.
So, today’s tip is to visit the SysInternals page on Microsoft‘s TechNet site and familiarise yourself with what is available. You might find that one day it will save you hours of frustration.
We are now in the middle of summer, however as I write this over a period of several days I can tell you that it has been chucking it down and it has been roasting.
If you are interested in SQL Server, the SQL Bits III conference (13th September) has now opened registration and session voting. They’ve opted to allow people to register for the event before they’ve even finalised which sessions are going to run. So, you could take pot luck and register now, or you can wait and see and take your chances that there will be places left.
I would have also been advising you of the ALT.NET conference in London (also 13th September) but when I last checked it was full already! Delegate Registration had only been open for a few days. If you’ve not signed up already there is always the Glasgow ALT.NET User Group. Added to that ALT.NET supporter Paul Cowan will be talking at Scottish Developers in Glasgow in September.
We also have exciting news that we have finally (and formally) merged with the North East Scotland .NET User Group. This gives us a permanent presence in Dundee. It also means that we should be able to put on events in Aberdeen from time-to-time. If you are from either city then get in touch and let us know what you’d like us to be putting on for you.
Our new committee is as follows: Colin Mackay (Chairman), Gary Short (Secretary), Frank Kerrigan (Treasurer), Barry Carr (UG Coordinator) and Craig Murphy (UG Coordinator).
As always, we are on the look out for new speakers. If you would like the opportunity to do a presentation on a software development topic from 10 minutes to 90 minutes then get in touch with me at colin@scottishdevelopers.com. If you are interested, but don’t think you have the skills to stand up and talk to a group of developers Microsoft are running some technical speaking training courses for those that want to speak to user groups. The courses will be held in Reading. The first is on 29th August. If you are interested drop me an email.
Regards,
Colin Mackay, Chairman, Scottish Developers
6-August-2008 @ 19:00 in Dundee (Scottish Developers)
An Introduction to Oxygene and its parallel coding features
FREE – Registration optional
Oxygene (formerly known as Chrome) is an advance .NET (and Mono) language by RemObjects influenced by Object Pascal. Oxygene has all the features of C# plus several more powerful features unique to itself. These include: Interface Delegation which provide a similar behaviour to Mixins; A null safe member access operator; Full support for “Design by Contract”; Virtual static members and Virtual constructors that can make writing object factories a breeze.
9-September-2008 @ 18:30 in Glasgow (Scottish Developers)
An Overview of ALT.NET Technologies
FREE – Registration optional
Most of the patterns and practices that come out of Redmond A.K.A Microsoft are purely to get a response from attendees of conferences like MIX. The same old drag and drop demo ware is both untestable and unmaintainable. Examples of such demo ware are the CAB application block, SCSF (smart client software factory), ObjectBuilder (a very poor IOC container) and the Entity Framework which many believe to be the catalyst for the ALT.NET movement. The recent ASP.NET MVC framework appears to be an acknowledgement from Microsoft that they want to embrace some of the ALT.NET concepts. The discussion will outline some of the following techniques and frameworks by way of a code review. Attendees are encouraged to participate with questions throughout the duration of the discussion. Some of he concepts and frameworks include: * Test Driven Development (TDD) * Nhibernate (Object Relational Mapper) * Castle Windsor (Inversion Of Control or Dependency Injection) * AOP (Aspect Oriented Programming) * ASP.NET MVC Framework * JQuery (a write less JavaScript library from a very talented team).
8-October-2008 @ 19:00 in Edinburgh (BCS)
The Three Ghosts of Microsoft Security
FREE – Registration Required
Taking efficiency one step further – F# Microsoft Research describes F# as “a scripted/functional/imperative/object-oriented programming language”. Combining all those aspects in one language is certainly not an easy task, but they’ve done a good job of it. F# is interesting both as a language to actually consider for your projects and as a source of features that might make it into the mainstream .NET languages tomorrow. The session uses many examples to give you a good general overview of F#. To complement the introductory session, Oliver is going to show some more advanced samples from his talk “Data Handling in F#” and there will also be room for Q&A as well as discussion.
September:
SQL Bits III (Hatfield)
October:
Frank Kerrigan talks about SSIS (Glasgow)
November:
VBUG Conference (Reading)
TechEd Developers (Barcelona)
Developer! Developer! Developer! (Reading)
December:
Andrew Westgarth on ASP.NET development on IIS7 (Glasgow)
SQL Know How are offering top quality SQL Server training courses at excellent value. Not only is the price great, but by entering the site from the links in this newsletter or on the Scottish Developer’s website you’ll get an additional 5% off the price. Their upcoming courses include the following
Best Practices in Performance and Availability for SQL Server 2005/2008
Kimberly L. Tripp and Paul S. Randal 1st – 3rd September 2008 Hatfield, Hertfordshire
Indexing for Performance in SQL Server 2000/2005/2008
Kimberly L. Tripp and Paul S. Randal 8th – 9th September 2008 Edinburgh
Smart Database Design
Paul Nielsen 22nd – 23rd September 2008 Hatfield, Hertfordshire
Smart Database Design
Paul Nielsen 29th – 30th September 2008 Edinburgh
SQL Server Data Storage Formats: Internals, Performance and Best Practices
Kalen Delaney 3rd November 2008 Harpenden, Hertfordshire
SQL Server Concurrency Control: Locking, Blocking and Row Versioning
Kalen Delaney 4th November 2008 Harpenden, Hertfordshire
SQL Server Data Internals and Tuning
Kalen Delaney 5th – 7th November 2008 Harpenden, Hertfordshire
If you prefer to use your keyboard more than your mouse then you may be interested in this set of keyboard shortcuts for Internet Explorer 6 and 7.
There is a meme going around at the moment and I thought I’d join in even although I’ve not been specifically tagged by it, it looks good fun. I spotted it on Phil Haak’s blog with his response.
I was 8 years old.
When my dad bought a ZX Spectrum in 1983 (It was a Mark II, 48K RAM). I started by typing in programs from the manuals, then by creating my own programs. One of the first I remember creating was to stop my sister using the computer. She was younger than me and the program was something like this:
10 PRINT “How old are you?”
20 INPUT a
30 IF a < 8 THEN PRINT “You are too young to use this computer.”; GO TO 10
ZX Spectrum Basic
The first real program that I wrote as part of a job was a tool to summarise and format certain data in a database. What today would be handled by a few drag & drop operations and some mouse clicks in SQL Server Reporting Services took me about a week or so back then. It was written in a language called Magik (yes, with a K)
Well various flavours of BASIC (ZX Spectrum, BBC, Visual Basic, VBA, etc.), COMAL (used by my high school), PASCAL, C/C++, COBOL, Magik, javascript, C#. There are probably a whole slew of other languages that I’ve touched over the years but not spent any significant time with that I’ve missed out here.
Yes, I would still have started programming. I probably would have done it a lot better though. There are a lot of things I’ve learned along the way that I wish I knew earlier. But, then again, if I never made those mistakes what lessons would I be learning? I guess I would be answering this questions pretty much the same way, but thinking of a different set of mistakes. Or would I? Maybe, since I didn’t make those mistakes in the first place I would end up being an incredibly arrogant insufferable arsehole.
Last year, I interviewed for 3 months to hire a developer. From that, the one major thing I think people need to understand is that in software development you must continue to learn constantly. I was interviewing candidates with 10+ years experience that had pretty much never learned anything since leaving university. Sure, they were using new languages since leaving, but they never learned about how to really use this fancy new object oriented language, or how to defend against SQL Injection Attacks. Most of them couldn’t even write a fizz-buzz program for goodness sakes.
So, my answer would be life long learning. If you don’t want to do it then do something else.
It is an interesting set of questions, and I’d like to know the answer from the following people:
Just a reminder to anyone that is interested that I’m speaking tomorrow (Thursday July 24th) Evening at VBUG in Manchester on the topic of SQL Server 2008 Spatial Queries, slide decks are available on my website.
You can limit the amount of memory that SQL Server uses by using the sp_configure stored procedure. By limiting the amount of memory that SQL Server is permitted to use it means that more memory is available to other applications or other instances of SQL Server. In fact books on-line recommends setting the minimum and maximum memory used on each instance of SQL Server running on the same machine as SQL Server does not make any attempts to balance memory usage across instances.
In order to use this you must be in an advanced mode. To set this up use:
EXEC sp_configure 'show advanced options', 1 RECONFIGURE WITH OVERRIDE
Next, to make the actual change you need the following:
EXEC sp_configure 'max server memory (MB)', 512 RECONFIGURE WITH OVERRIDE
The above example will set the maximum amount of memory the server will use to 512MB. The RECONFIGURE WITH OVERRIDE is necessary in order for the change to take effect immediately. If it is missed out then the change won’t take place until the SQL Server is restarted.
If you want to check that the change has taken place you can use the following:
EXEC sp_configure 'max server memory (MB)'
This will just display the current setting. You will get a result set that looks something like this:

The congif_value is the value that the SQL Server is currently configured with. However, it may not be what is currently in force. The run_value shows you what is currently in force.
If you don’t want to type so much SQL yourself, then you can do the same in the SQL Server Management Studio. Right-click the server in the object explorer and select “properties” from the context menu. This will bring you up a dialog with all the server level properties in it. Go to the “memory” page and you can set the values that you want there. There are a couple of radio buttons that will allow you to switch between the currently configured value and the running value. By pressing Okay the updated value is applied to the server immediately.
For more information:
This is the 5th part in a series on LINQ to XML. In this instalment we will look at monitoring changes in XML data in the XML classes added to .NET 3.5.
The XObject class (from which XElement and XAttribute, among others) contains two events that are of interest to anyone wanting to know about changes to the XML data: Changing and Changed
The Changing event is triggered prior to a change being applied to the XML data. The Changed event is triggered after the change has been applied.
An example of adding the event handler would be something like this:
XElement root = new XElement("root"); root.Changed += new EventHandler<XObjectChangeEventArgs>(root_Changed);
The above example will trigger for any change that happens in the node the event handler is applied to and any node downstream of it. As the example is applied to the root node this means the event will trigger for any change in the XML data.
The event handler is supplied an XObjectChangeEventArgs object which contains an ObjectChange property. This is an XObjectChange enum and it lets the code know what type of change happened.
The sender contains the actual object in the XML data that has changed.
Take the following example where an element is added to the XML data.
XElement child = new XElement("ChildElement", "Original Value"); root.Add(child);
In this case the ObjectChanged is Add and the sender is the XElement: <ChildElement>Original Value</ChildElement>
A similar scenario happens when adding an attribute. However, instead of the sender being an XElement it will be an XAttribute.
child.Add(new XAttribute("TheAttribute", "Some Value"));
If the value of the element is changed (the bit that currently says “Original Value”) then we don’t get one event fired. We get two events fired. For example:
child.Value = "New Value";
The first event with ObjectChanged set to Remove and the sender set to “Orginal Value” (which is actually an XText object) and the second event with the ObjectChanged set to Add and the sender set to “New Value” (again, this is actually an XText object).
If the name of the element is changed then the ObjectChanged property will be set to Name and the sender will be the XElement that has changed.
child.Name = "JustTheChild";
Unlike changing an element value, when the value of an attribute changes the ObjectChanged property will be Value and the sender will be the XAttribute.
child.Attribute("TheAttribute").Value = "New Attribute Value";