我有一个错误,它说:“查询Expression中的语法错误(缺少运算符)。
这是我的代码:
"SELECT AttHadir.IDUser, Hadir.NamaUser, AttHadir.JamMasuk, AttHadir.Threshold," & _
"AttHadir.ModVerifikasi, AttHadir.ModVerifikasi FROM AttHadir INNER JOIN Hadir ON AttHadir.IDUser = Hadir.IDUser" & _
"WHERE AttHadir.IDUser='" & TBox(0).Text & "' AND MONTH(AttHadir.JamMasuk) AS Bulan ='" & Combo(0).Text & "'" & _
"AND YEAR(AttHadir.JamMasuk) AS Tahun='" & Combo(1).Text & "'"
每个人都知道我的代码是正确的吗? 感谢
答案 0 :(得分:0)
您的字符串将创建为:
SELECT AttHadir.IDUser, Hadir.NamaUser, AttHadir.JamMasuk, AttHadir.Threshold,AttHadir.ModVerifikasi, AttHadir.ModVerifikasi FROM AttHadir INNER JOIN Hadir ON AttHadir.IDUser = Hadir.IDUserWHERE AttHadir.IDUser='' AND MONTH(AttHadir.JamMasuk) AS Bulan =''AND YEAR(AttHadir.JamMasuk) AS Tahun=' '
我认为您在AttHadir.ModVerifikasi
,WHERE AttHadir.IDUser
和AND YEAR(AttHadir.JamMasuk)