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.

The SQL Server backup – foundation of any Disaster / Recovery

Welcome to our second class for HA and DR week of SQL University. Yesterday we went through defining HA and DR along with some common practices you can use. Today we are going to focus on the concept, “Backups are for sissies!” OK, we’re really going to look at backup and restore for Disaster / Recovery (DR) and how being a sissy and always backing up our databases and testing out restores is a proven strategy for DR.

Read More...

Welcome to HA and DR week!

Welcome to SQL University HA and DR week! My name is Ted Krueger and I will be covering various High Availability and Disaster Recovery (HA and DR) strategies and methods. During the week, we will talk about defining HA and DR and introduce some points to consider while putting them into practice in your centers. Next, we will go over DR. The DR class will be composed of a Log Shipping setup and also a backup/restore discussion.

Read More...

Tuples in VB10

In .Net 4.0, and VB10 that goes with that, you can now use a new type called a Tuple. The Tuple is not very fancy and something that is overlooked sometimes but it can be very handy on occasion. This is what wikipedia has to say about a Tuple In mathematics and computer science a tuple is an ordered list of elements. In set theory, an (ordered) n-tuple is a sequence (or ordered list) of n elements, where n is a positive integer.

Read More...

How to refresh the local IntelliSense cache in SQL Server Management Studio

This question came up again yesterday in our SQL Server forum so I decided to create a short blog post about it. The version of SQL Server Management Studio that ships with SQL Server2008 comes with IntelliSense enabled, I still think IntelliSense is sometimes more in my way than it is useful but I won’t bore you with that. What will eventually happen is that if you create new tables and stored procedures IntelliSense will not know about those, when this happens you have to refresh the local IntelliSense cache for it to see the new objects.

Read More...

Removing old files with SSIS

This post will illustrate two methods for removing old files from directories using SSIS. This task is often used to delete old backup files and other ETL files that are not required any longer. We’ll step through two methods. First method uses a script task entirely for the removal and the logging events. This method will also have some comments in for logging and using the FireInformation method to mimic the normal logging abilities of SSIS.

Read More...

Not all memoryleaks are the same and USER objects.

I have an application that is used on a bigscreen TV to show some stats and calender things. The application runs 24⁄7. It is not something that I want to spend lots of time on. After I made some changes to the application it started crashing every 12 hours or so. The time it took to crash seemed pretty consistent too. Just restarting the app would work but gets annoying after the second time.

Read More...

Error: The GetBytes function can only be used on columns of type Text, NText, or Image

This is just a quick post in case you run into this problem. This is an interesting error and it had a coworker worry about table corruption. This coworker connected to a database on a fairly new server, he then executed a query like the following SELECT * FROM SomeTable And here is the error message he got An error occurred while executing batch. Error message is: Invalid attempt to GetBytes on column 'BookDate'.

Read More...

.Net 4 And the reportviewer

Switching to a new framework can be fun at times. This time I had a little problem with the Reportviewer. Report execution in the current AppDomain requires Code Access Security policy which is off by default in .NET 4.0 and later. Enable lagacy CAS policy or execute the report in the sandbox AppDomain. I like the and later part. Here is the printscreen, just in case you don’t believe me.

Read More...

Twisting My Arm – How I was Persuaded to Change StructureMap Versions

I’ve been using StructureMap 2.5x for some time, and I have been quite pleased with it. I’d read a bit about 2.6x, and the improvements to the registry DSL seemed cool but not quite cool enough to give me the motivation I needed to make upgrading the version used in my project a priority. A week or two ago, I found what proved to be my compelling reason. It’s a method called

Read More...

Programatically create a sharepoint calendar entry

We recently had a requirement to programatically create an entry in an existing Sharepoint calendar, so here is an example of how we went about doing this. I’ll be using Visual Studio 2008 for this, but the process will be similar for any other versions you are using. First of all, you will need to add a reference to one of the Sharepoint web references, so right-click your project and select Add Web Reference.

Read More...