access 中要查找某日期字段,这样写SQL为什么老出错啊?请大侠指教,谢谢!

来源:百度知道 编辑:UC知道 时间:2024/06/17 07:06:53
select * from t_xinxi where BIRTHDAY=#"+DateTimePicker1->Date+"#

楼主的写法是MYSQL的。ACCESS这样写
SQL="select * from t_xinxi where BIRTHDAY='"+DateTimePicker1->Date+"'"

楼主最后少了一个双引号"

ACCESS的传入时间是要加#号的

select * from t_xinxi where BIRTHDAY=#+DateTimePicker1->Date+#