By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,983 Members | 2,035 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,983 IT Pros & Developers. It's quick & easy.

syntax error in query experession

100+
P: 198
Hi
i am running a date query

squery = "Insert into " & txttablename & " IN '" & txtdatabase & " ' select * from " & sTableName & " IN '" & txtfolderpath & "\" & sArrFolder(icount) & "\" & sDirFolder & " ' where Yp1VStartTime <= " & DTPstart & " and YP1VEndTime >= " & DTPEnd & " "


but it is showing this error i,e
syntax error (missing operator ) in query expression Yp1VStartTime <= 4/14/2008 2:30:00 PM and YP1VEndTime >= 4/14/2008 10:00:00 PM

please check my query and give some idea
pleasssssssssse
varinder
Apr 23 '08 #1
Share this Question
Share on Google+
4 Replies


debasisdas
Expert 5K+
P: 8,127
is that an SQL ?

i don't think so.
Apr 23 '08 #2

100+
P: 198
Hi
i am accessing access table data from vb 6.0
thanks
is that an SQL ?

i don't think so.
Apr 23 '08 #3

debasisdas
Expert 5K+
P: 8,127
You need to learn SQL before trying to execute them from VB.

Learn the basics of SQL first.
Apr 23 '08 #4

lotus18
100+
P: 866
Hi
i am accessing access table data from vb 6.0
thanks
Debasisdas is right. You need to check your query first. BTW, what are you trying to achive? P.S. use code tags.

Rey Sean
Apr 23 '08 #5

Post your reply

Sign in to post your reply or Sign up for a free account.