Few days back, I discovered this error that SQL Server DateTime can hold only dates between 01-Jan-1753 12:00:00 AM to 31-Dec-1999 11:59:59. While performing a random data entry in SQL Management Studio, it alerted me this error message:
The text version of Error Message:
Microsoft SQL Server Management Studio
No row was updated.
The data in row 1 was not committed.
Error Source: System.Data.
Error Message: SqlDateTime overflow. Must be between 1/1/1753 12:00:00 AM and 12/31/9999 11:59:59 PM.
Correct the errors and retry or press ESC to cancel the change(s).
If you are a Web Developer, then it becomes important for you to handle this exception in your application. Based on the feasibility of your Application Design, you can follow one of these common methods:
- On the Server Side script – ASP.NET, PHP, JSP etc.
- You can also catch this error at the back-end layer, if your design includes Stored Procedures.
So far, I have verified this problem in SQL Server 2005, SQL Server 2008 and SQL Server 2008 R2.
Next time, when I get time I will explore any such Date Time value limitation in other popular databases.
I am just guessing that Mainframe Databases will not have such limitations, because they store the data in plain text. Hope some Mainframe expert reads this posts and confirms my assumption
Today (technically 10-Aug-2010 US Time), Microsoft pushed a bunch of Security Update patches to Windows operating system. I received the following updates on my Windows XP SP3:
Installing Security Update for Windows XP (KB982665) (update 1 of 12)… done!
Installing Security Update for the 2007 Microsoft Office System (KB2277947) (update 2 of 12)… done!
Installing Security Update for Windows XP (KB981997) (update 3 of 12)… done!
Installing Windows Malicious Software Removal Tool – August 2010 (KB890830) (update 4 of 12)… done!
Installing Security Update for Windows XP (KB980436) (update 5 of 12)… done!
Installing Security Update for Windows XP (KB2160329) (update 6 of 12)… done!
Installing Cumulative Security Update for Internet Explorer 8 for Windows XP (KB2183461) (update 7 of 12)… done!
Installing Security Update for .NET Framework 2.0 SP2 and 3.5 SP1 on Windows Server 2003 and Windows XP x86 (KB983583) (update 8 of 12)… done!
Installing Security Update for Windows XP (KB2079403) (update 9 of 12)… done!
Installing Security Update for Windows XP (KB981852) (update 10 of 12)… done!
Installing Security Update for Windows XP (KB2115168) (update 11 of 12)… done!
Installing Security Update for Windows XP (KB982214) (update 12 of 12)… done!
Notice the Update # 10 which is KB981852. After all the above updates, it prompted me to restart my computer. I followed the instruction and after logging into my computer, I was surprised to see that it once again found KB981852 update and prompted me to download/install:
I followed the instruction and clicked on Download and later install. This time I was not prompted to restart my computer. But, after few seconds I again got a indicator in my task bar that it found KB981852 update. This is going into loops. I tried running this 3 times; I even restarted my computer, but still I am getting this update.
Did anyone discovered this problem? @Microsoft – Is this a known issue?
Update: 18-Aug-2010: Thanks for comments by all readers. So it looks like a known problem for many others. My Control Panel shows that this update is installed successfully(refer below screen shot), but I am still getting a notification to install this update in the task bar. The same update was installed on my other Windows 7 computer, which did not have face this problem.
Update: 25-Aug-2010: Problem still continues on Windows XP. I even tried removing the above Update and tried to install it again. But after every install, it again gets this new update and shows the notification in the task bar. Did anyone found the fix from Microsoft?
Update: 07-Sep-2010: Today when I received the Update for Microsoft Silverlight (KB2164913), I just realized that the looping problem of KB981852 has disappeared. I am not getting any more alerts for KB981852. Hope the same applies to everyone who faced this problem!