Types of Questions

Open Questions

Open a subject.

“How do you feel about…?”

Closed Questions

Gather and confirm specific facts.

“Do you want me to…?”

Focusing Questions

Focus on a topic that has been raised.

“You mentioned… earlier. What is the best way to acheieve this?”

Probing Questions

Explore a subject in more depth.

“Can you give me an example of…?”

Reflective Questions

Reflect on what has been said to confirm shared understanding.

“It seems you are suggesting… Is that right?”

Posted in Uncategorized | Leave a comment

Gogo’s Crazy Bones

My son was crazy about Gogos for a while, so we drew these silhouettes for printing on stickers etc.

You’re free to use these illustrations in any way you wish.

Posted in Family Life | Leave a comment

VBScript to Get Domain Groups for Current User

This take me back a bit…

[sourcecode language="vb"]
Option Explicit

' Get the current user's domain and username.
Dim wsxNetwork
Set wsxNetwork = CreateObject("WScript.Network")

Dim sDomain, sUser
sDomain = wsxNetwork.UserDomain
sUser = wsxNetwork.UserName

' Get the user.
Dim objUser
Set objUser = GetObject("WinNT://" & sDomain & "/" & sUser)

' We'll build a list of group names.
Dim sGroupNames

' For each of the groups for the user...
Dim objGroup
For Each objGroup In objUser.Groups

    ' Add the group name to the string.
    sGroupNames = sGroupNames & objGroup.Name & vbCrLf


' Show the list of groups.
MsgBox sGroupNames
Posted in VBScript | Leave a comment

When Improving Technology Makes Things Worse

A Secret

We all know that bad technology is bad for business. By “bad” I mean technology that doesn’t do what it is supposed to do, or which does it wrong, or which costs more to implement than the benefits it brings.

But I’ll let you in to a secret:

Good technology is sometimes bad for business.

Now, I develop software for a living, so I shouldn’t really be telling you that. I should be saying that good technology is a good thing – especially software – and that it will increase your bottom line, make you more productive, make you happier and generally improve your life.

And each of these things is true… but only some of the time.

The Problem

The problem is this:

  • Good technology makes processes more efficient.

At first sight, this sounds like a good thing. To understand why it often isn’t so good, consider two effects that technology will have on an organisation:

Efficiency and Effectiveness

According to Jim Collins (in Good to Great), “great” organizations all employ technologies that enhance their competitiveness. Collins also confirms the role that technology can play if you don’t keep up. However, he explains that technologies are accelerators that amplify the company’s strengths and weaknesses. This means that a company that aims to improve processes by adding technology will magnify both the good and the bad aspects of those processes. In any business area where practices are less than perfect, the imperfections will be amplified by technology. The problem is that making processes more efficient doesn’t necessarily make them more effective.


The other effect of introducing technology is that it can be a hindrance to change. A new software system, for example, can be a very costly acquisition (especially given that companies often underestimate the cost of software). Once the software is deployed, however, processes become locked-in to the way the software operates. Changes to processes often require changes to the software – which can be prohibitively expensive. The result is that the company looses agility, becoming bound to outdated practices that they know are broken, that they want to change, but which are impossible to shed because of technical constraints.

An example of this is the clocking system that was used at a company where I did some work. It was based on decimal hours rather than hours and minutes, so 7 hours and 30 minutes appeared on screen as 7.5. Everyone knew that this was a bad idea, because the entire staff of the company wasted time every month converting their clockings from hours and minutes into decimal hours. However, this method of working was locked in by the technology. When a companion time-sheet system was introduced, the specification indicated that it should also work in decimal hours so it would be compatible with the first system, further locking-in wasteful behaviour.


So, does all this make all technology a bad thing? Not at all. But it does suggest that we approach technology in a different way:

  • Great companies value technology.
  • Technology should not bee seen as a panacea, but a method of amplifying existing practices.
    • Business needs should drive technology, not the other way around.
    • Business systems should be fixed before introducing technology to make them more efficient.
  • Technology should be chosen on the basis of how easy it is to change as well as on how well it meets current needs. For example:
    • Choose an Agile approach to bespoke software development.
    • Reduce dependencies between technologies.
Posted in Best Practice | Leave a comment

.Net Implicit Casts


A cast is a conversion of data from one type to another, for example from an integer to a float.

Implicit Casts

An implicit cast is a conversion from one type to another that is automatically assumed by the compiler. Therefore, an implicit cast does not appear in the program code.

In general, implicit casts can only be made when the conversion does not result in loss of information. This means that an implicit cast cannot be performed where the value being converted must be rounded or truncated.

C# Implicit Casts

sbyte byte short ushort int uint long ulong float double decimal
FROM sbyte x x x x
byte x
char x x x
short x x x x x
ushort x x x
int x4 x4 x4 x4 x4 x4 1 1
uint x x x x x 1 1
long x x x x x x x 1 1
ulong x x x x x x x 1 1
float x x x x x x x x x3
double x x x x x x x x x x3

Notes on the Table

  1. May cause loss of precision but not magnitude.
  2. There are no implicit conversions to char.
  3. There are no implicit conversions from floating-point types to decimal.
  4. Constant expressions can be converted provided the constant expression is in range of the destination type.

VB.Net Widening Casts

SByte Byte Short UShort Integer UInteger Long ULong Single Double Decimal
FROM SByte x x x x
Byte x
Short x x x x x
UShort x x x
Integer x x x x x x 1 1
UInteger x x x x x 1 1
Long x x x x x x x 1 1
ULong x x x x x x x 1 1
Decimal x x x x x x x x 1 1 x
Single x x x x x x x x x
Double x x x x x x x x x x
Char Char array String
FROM Char x
Char array x
String x x

Notes on the Tables

  1. May cause loss of precision but not magnitude.

Explicit Casts

An explicit cast requires special syntax in the source code.


C# VB.Net Data Types Restrictions Runtime Failure
CType Value and Reference Types Widening or narrowing conversion must be defined between the two data types Throws InvalidCastException
Cast Operator DirectCast Value and Reference Types One type must inherit from or implement the other Throws InvalidCastException
as TryCast1 Reference types only One type must inherit from or implement the other Returns null (C#) or Nothing (VB.Net)

Notes on the Table

  1. Later versions of VB.Net only.
Posted in C#, VB.Net | Leave a comment

SQL Server: Example Naming Convention

An example of a SQL Server naming convention I have encountered:


  • tcTableName (e.g. tcAsset) for core tables, i.e. tables that contain regularly changing data and have insert/update/delete queries run against them.
  • trTableName (e.g. trAssetType) for reference tables, i.e. tables that contain static/unchanging data, usually used in reference to data in core tables.
  • tjTableName (e.g. tjUserRole) for join tables, i.e. tables that provide a many-to-many join between two other tables.


  • tableNameId (e.g. assetId) for primary keys.
  • foreignTableNameId (e.g. assetTypeId) for foreign keys.
  • name” for text fields in simple ID/Name tables, e.g. in trAssetType (assetTypeID int, name nvrachar(100)).
  • lowerUpperUpper (e.g. propertyEntranceStorey) for all other columns, with no particular convention on the column names other than the lowerUpperUpper case.


  • vwTableNameSubset (e.g. vwAsset, vwWindowHistory, vwWindowHistoryLatest)


  • Stored Procedures: uspTableAction (e.g. uspAssetDelete) (usp = User Stored Procedure – don’t use “sp” as its reserved for system stored procedures and SQL Server always checks the Master database for the SP first before checking the current database, meaning its bad for performance).
  • Functions: fnXXX
  • User-defined Data Types: uddtXXX
  • ID Columns: tableID / foreignTableID (e.g. assetID / assetTypeID)
Posted in SQL Server | Leave a comment

What Makes Technology Popular?

It is easy to assume that technology becomes popular simply because it is better than the competition. But as the saying goes, “that ain’t necessarily so”. In fact, the history of innovation is replete with examples of inferior technologies capturing a larger market share than their technically superior rivals.

Some of the best known (and hotly debated) examples of include:

  1. Betamax / VHS
  2. Ethernet / Token Ring
  3. Mac / Windows
  4. Firefox / Internet Explorer

Moreover, there are also plenty of perfectly good technologies that die a death because they lag far behind their rivals in terms of sales, despite their being little difference in their technical merit. Most format wars are a case in point.

So, why does this happen? How does a technology come to dominate the market, often at the expense of other, sometimes superior, alternatives?

Pick Me! Like Donkey, some technology has what it takes to get picked.

The answer lies in the way that individuals make decisions about the technology they use. The technology that gets picked for three reasons:

  1. It meets a need (or at least appears to)
  2. It gets publicity – sometimes through deliberate advocacy, sometimes through word of mouth
  3. There costs of adoption are outweighed by the benefits

To illustrate, we’ll consider a well-known example: the Windows operating system.

Firstly, users who get what they need from Windows are unlikely to go looking for alternatives. They might do so, however, if they start to believe that their are problems with Windows that reduce their productivity. For the majority of Windows users, however, Windows meets their needs. Whether that is because it is a great product or because the users don’t know any different is irrelevant. The point is that for many users, it is simply good enough.

Secondly, even if they go looking, Windows users are unlikely to find out about many of the alternatives. This is because they just don’t receive very much attention from developers, other users nor the press. How many Windows users have heard of the Haiku Operating System, for example? On the other hand, it is more likely that they will have heard of the Mac or Linux.

Finally, even if Windows users find an alternative, they won’t switch unless the benefits of switching outweigh the costs of adopting the new platform. If critical applications are available on the new platform, users might switch. If not, they are unlikely to do so. Similarly, if the learning curve is steep, they may be reluctant, but if the user experience is similar, they may be more willing to do so. Ubuntu is a popular Linux distribution because of the focus on usability, whereas others are less so because they’re difficult to get used to.

So, there you have it: technology is not popular just because it is good (although that helps), but because of market forces – marketing in particular.

Thanks to the jgauffin for the inspiration behind this post.

Posted in Uncategorized | Leave a comment

C#: How to Clone a Generic List

Found on StackOverflow, this is a tidy example of an generic extension method that uses LINQ:

[sourcecode language="c#"]
static class Extensions
    public static IList Clone(
        this IList listToClone) where T: ICloneable
        return listToClone.Select(item => (T)item.Clone()).ToList();
Posted in C# | Leave a comment

How to Improve Service and Lower Costs

Focus on the systems that provide value

How you view a problem is the key to the way you solve it. If our focus is on anything but the systems that provide value we will be driving waste into our business.

Don’t focus on economies of scale

Standardisation isn’t always improvement

Don’t focus on tools, but on principles

Every situation is different.

At a high level, the ways that a service organisation provides value are different from a manufacturing business or an R&D department. This is why lean tools don’t translate to service organisations.

At a low level, each organisation has a different pattern of demand for its services. This leads to different problems which require different types of solutions.

Don’t focus on individual processes

Efficient processes don’t always lead to efficient systems.

Consider the value stream. Costs arise from end-to-end services, not individual transactions. Lowering individual transaction costs can increase overall transaction costs.

However, poor performance in one area has a knock-on effect in other areas.

Focus on providing better end-to-end services

  • Better service lowers costs
  • Follow the value flow, eliminate waste
  • Fragmentation of flow introduces waste (e.g. separating back-end from front-end breaks up flow)
  • Improve systems  – systems control behaviour

Create better measures

  • High scores don’t add value
  • Measures should relate to the purpose of the system from a customer POV


Posted in Best Practice, Leadership | Leave a comment

Improving the Information Service

A grab bag of ideas:

Focus on business value

Nothing else matters.

Provide a great interface

At these levels:

  • Technically
  • Personally

It should be:

  • Easy to access
  • Responsive
  • Reliable
  • Make people feel good

Build a solid, agile infrastructure

You’re going to pay interest on technical debt. So keep your implementation clean.

Where appropriate:

  • Simplify
  • Consolidate
  • Standardise


  • Hardware
  • Software
  • Configuration
  • Names

And remember:

  • If you’ve got one, you’ll need two.

Don’t think savings, think investment

Invest in:

  • Staff
  • Tools
  • Infrastructure

Know your assets

For each key asset:

  • Know its value to the business
    • What would you do if it wasn’t there?
  • Know what it costs
    • To buy
    • To replace
    • To maintain
    • To use
    • Of alternatives
  • Know who is responsible for it
    • Within IT
    • Within the business
    • Outside (contracts, supplier)
  • Know its limitations
    • Technical
    • Legal (licensing etc.)
  • What it depends on
    • Hardware
    • Software
    • People

Emphasize quality over quantity

  • Get it right first time
  • Do less and do it better
  • If you can do it once, you can do it twice



Posted in Leadership | Leave a comment