Menu

Friday, September 17, 2010

Unable to convert MySQL date/time value to System.DateTime

My database have a column named update_link, datetime type, that constants a row with zero value(0000-00-00 00:00:00). Then each times i try to select row i got this.
This's a solution: add "allow zero datetime" to you connection string

String conn = "SERVER=127.0.0.1;DATABASE=MoodleService;UID=root;PASSWORD=123456";allow zero datetim=true;

Hope this helps

PS: This's first time i writed an article by english, there're some stupid paragraph becuz my english is not good,please tell if you canot understand ^^

No comments:

Post a Comment