NewsDemon Banner

Anyone who has worked with a database for even a short amount of time has undoubtedly checked the number of rows in a table with a statement akin to this:

SELECT COUNT(*) FROM dbo.TableName

It’s quick and easy, but is expensive in terms of logical reads. Also, things get complicated when you want to check the numbers of rows for all user tables in an entire database – you might think about resorting to cursors and dynamic SQL.

Fortunately, SQL Server 2005 shipped with a whole slew of Dynamic Management Views that make monitoring your database much simpler. With a quick query, we can view the rowcount for all tables in a database – and no table scan required.
Read the rest of this entry »

I came upon the need to calculate the number of weekdays between two dates. SQL Server offers several utilities for calculating dates, but nothing for this specific purpose. After staring at a calendar for some time and going through several revisions, I came up with a solution that seems to work pretty well. I do rely on 1 helper UDF, but it’s a pretty standard function that can easily be used elsewhere. Please note that I’ve designed the main function to be language independent—that is, it does not depend on @@DATEFIRST to be set any particular way.
Read the rest of this entry »

A very common task for database developers taking reigns of an existing project is to normalize data. I needed a convenient way to split delimited values into a table for transformation purposes. After finding a wonderful algorithm, I decided to enhance it and transform it to a User-Defined Function in the process. Be aware that the function depends on a Tally table to exist – much like you might have with a Calendar table to join against.
Read the rest of this entry »

Up until this morning, I have been using NuevaSync to act as a conduit between my iPhone and Google accounts. Unfortunately they hit a hiccup this morning, ceasing all sync’ing. In an effort to remedy the situation, I turned off sync’ing for contacts (which deletes all contacts), then turned it back on, only to later discover things were completely broken and leaving me without a contact list. Until the service is back up, I found a quick solution to restore the missing information.
Read the rest of this entry »

Google just released Chrome, their WebKit-based browser. My initial impressions are pretty good. I like the new interface – especially the expanded vertical room. It seems very fast, especially on existing JavaScript-heavy sites like Gmail, Reader, and Maps. It almost seems that Chrome is caching emails and feeds in the backgrounds so everything loads quickly.
Read the rest of this entry »

  • Graham Charles: I've been considering using this approach to forward individual users' e-mail, but I'm curious if th [...]
  • Paden: Ok another 15min all sorted. something between changing default account on iphone to the exchange go [...]
  • Paden: Thank you I'm sooo close! Same thing as Brandon & Krlrvr. How does one make Google calendar disp [...]
  • Yushe » Blog Archive » Conectar SQL Server con MySql: [...] Disclaimer: El árticulo arriba no es mio, es solo una traducción parcial del árticulo aqui [...]
  • Nick: Here is an extensive how to on sharing folders with Windows 7. http://www.ilertech.com/2010/09/shar [...]


This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 United States.