http://www.sqlservercentral.com/blogs/steve_jones/2005/09/14/whoops/ Printed 2015/09/01 05:09PM
WhoopsI setup an announcement for today (Sept 14) that the Sept CTP for SQL
Server 2005 was released and that Database Mirroring is disabled. It's
also got more language support and a few other things.
Apparently, however, my coding skills were a bit challenged. I forgot a
primary rule in working with data, especially outside of SQL Server.
x > "10" does not equal x > 10
I setup a time check based on the current time and a number I was
checking, but I used the first expression, which is a string comparison
expression. So "2", "3", etc. are all > "10". Only "1" would be
less. So the article text got released a little early and hopefully MS
isn't too upset :(
I've gotten so used to working with SQL Server data and I always check
the time values when working with dates. In VBScript, however, it's a
little more complicated. I should have used the CINT() function to
ensure I was comparing a numerical value and then comparing that to a
numeric, 10, not "10".