日期:2014-05-17  浏览次数:20809 次

输入项无法被转换为有效日期时间值--这是什么原因
SELECT     emp_id, Diary_date, diary_valid, diary_errcheck, Diary_class, Diary_time, Diary_ic, Diary_type, Diary_state, Diary_normal, Diary_day, Diary_ov, 
                      diary_abnhour, diary_abnday, diary_late, diary_soon, diary_classsub, diary_forget, diary_reason, diary_lea1, Diary_time1, Diary_lea2, Diary_time2, 
                      diary_create_time, diary_user, diary_abn, diary_key, diary_watch, diary_ovday, diary_waged_type, diary_pic_ov, diary_ov_nbr, diary_ov_ok, 
                      diary_pic_nor, diary_ov_apphours, diary_remark, diary_late_num, diary_soon_num, diary_ov_okdate, diary_lock, diary_maxcard, 
                      diary_series_abnday, diary_ovtest, diary_cclevel, diary_cccode, diary_night_small, diary_night_big, diary_max, diary_abnday_number, 
                      diary_class_on1, diary_class_off2, diary_card_end, diary_week, diary_ov_nextday, diary_type_nextday, diary_ov_off1end, Diary_time3, Diary_lea3, 
                      diary_class_on2, diary_class_off1, diary_ic_today, diary_forget_on, diary_forget_noon1, diary_forget_noon2, diary_forget_off
FROM         H_diary
WHERE     (emp_id = '100020') AND (Diary_date BETWEEN '2012 -11- 01' AND '2012-11 -31')


提示输入项无法被转换为有效日期时间值
------解决方案--------------------
 这个是运行提示
------解决方案--------------------
2012-11-31这个错了,11月份没有31日的

------解决方案--------------------
明白了,谢谢!
------解决方案--------------------
11月哪有31号的