LessThanDot Site Logo

LessThanDot

A decade of helpful technical content

This is an archive of the posts published to LessThanDot from 2008 to 2018, over a decade of useful content. While we're no longer adding new content, we still receive a lot of visitors and wanted to make sure the content didn't disappear forever.

What was your first computer and what were some of your favorite games?

The first computer I ever bought was a commodore 128 (I actually received it as a gift for my 16th birthday) This baby had 128K (not MB) of RAM, 4 sound channels and 16 colors With the C128 you had a C64 built in and you could run CP/M (it came with a floppy) I almost always booted up C64, this gave you 39KB free memory to use, the speed was 1MHZ, the C128 could run at 2MHZ but then the screen would go dark before you switched back to 1MHZ.

Read More...

A Recipe for Success: The Command Pattern, StructureMap and a dash of Generics

So you have lots of forms in your winforms application and you have to open them from several places/forms. But you don’t want to repeat yourself all the time. And you like to keep things centralized. You also want it to be flexible, if possible and easily extendable/extensible/extendingable, uhm, be able to extend it in an easy manner. I think this is a typical case for the command pattern. So let’s start with that.

Read More...

Debian GNU/Linux 5.0 Lenny released

Debian GNU/Linux 5.0 has been released This is part of the announcement The Debian Project is pleased to announce the official release of Debian GNU/Linux version 5.0 (codenamed “Lenny”) after 22 months of constant development. Debian GNU/Linux is a free operating system which supports a total of twelve processor architectures and includes the KDE, GNOME, Xfce, and LXDE desktop environments. It also features compatibility with the FHS v2.3 and software developed for version 3.

Read More...

SQL Friday, The Best SQL Server Links Of The Past Week Episode 11

Here we are with another mesmerizing episode of the SQL Friday, The Best SQL Server Links Of The Past Week show. Here is what I found interesting this past week in SQL Land: All indexes are unique Gail Shaw tells us about the uniquefier which makes indexes unique Performance impact: a large number of virtual log files – Part I Performance impact: a large number of virtual log files – Part II

Read More...

SQL Server 2008 Proximity Search With The Geography Data Type

George and I decided to show you how you can do simple radius searches based on Zip Codes, he did the SQL 2005 and before version here: SQL Server Zipcode Latitude/Longitude proximity distance search and I will do the SQL Server 2008 version. The first thing we need to do is load our data. There are various sources for this data, ranging from free to expensive monthly subscriptions. One source of free data is: http://download.

Read More...

SQL Server Zipcode Latitude/Longitude proximity distance search

Have you ever wanted to add functionality that allows you to perform simple radius searches based on Zip Code? For example, Show me all the cities within 20 miles of a certain zip code or show me the 5 closest retail locations. You can easily add this functionality to your database by importing a zip code database and writing a little code. This article will show you where to get zip code data, how to import it to your database, and how to use the data to perform proximity searches.

Read More...

Kaspersky Web Site Hacked With SQL Injection, How Embarrassing Is This?

We all know that Kaspersky is a security firm and they make a very nice product, you can see a list of their products here: http://www.kaspersky.com/ What I found out today on twitter is that their site got hacked by a SQL Injection attack. The tool that was used was the Acunetix Web Security Scanner. Tools are used by admins to protect their sites but the same tools are also used by hackers to attack your site.

Read More...

Suppress string or binary data would be truncated messages with the ANSI WARNINGS setting

String or binary data would be truncated. How can I suppress that message? This is a frequent enough question on various forums, I answered this one also today and decided to create a quick blog post about this. Run this code create table bla(id varchar(2)) go insert bla values ('123') You will get the following message: Server: Msg 8152, Level 16, State 14, Line 1 String or binary data would be truncated.

Read More...

VB.Net: Reflection and a private field marked with WithEvents

If you have this piece of code. ```vbnet Public Class Test Private WithEvents _Obj as ObjectWithEvents … End Class``` And you want to get the Value of that field via reflection using C# because for some reason you just do. Trust me. csharp var objectWithEvents = testinstance.GetType().GetField("_Obj", BindingFlags.NonPublic | BindingFlags.Instance).GetValue(testinstance); Then know that the above will fail. Because VB.Net just happens to add an extra underscore to fields marked with WithEvents.

Read More...

Installing SQL Server 2008 express on Windows XP SP 2 without reading the manual

Today I was going to write a blogpost about persisting the simple domainmodel using Nhibernate and Fluent Nhibernate (I will have to write this later). It turned out to be quite and adventure. First I finaly installed R# on this machine I’ve been having the license since last octobre just haven’t used it yet on this or any other machine. That installation was pretty painless I must say. Then I needed to install some kind of database.

Read More...