Query Trouble

Results 1 to 2 of 2

Thread: Query Trouble

  1. #1
    Join Date
    Dec 1969

    Default Query Trouble

    Hi<BR><BR>I recently updated to Access 2000, and have stumbled across some problems with a query.<BR><BR>I have used the poll system from 4guys and it has worked just fine.<BR><BR>When I run the query I get "Syntax error in date in query Poll.DateStart&#060;=#27.04.00# AND Poll.DateEnd&#062;=#27.04.00#<BR><BR>27.04.00 is todays date which I have collected using VBscripts Date function.<BR><BR>The complete query looks like this:<BR><BR>"SELECT PollOption.PollOptionID, PollOption.QuestionText, PollOption.Votes, Poll.PollQuestion FROM Poll INNER JOIN PollOption ON Poll.PollID = PollOption.PollID WHERE Poll.DateStart &#060;= #"& Date &"# AND Poll.DateEnd &#062;=#"& Date &"#"<BR><BR><BR>In the database I have set the datefields to use the short date format.<BR>Any help would be greatly appreciated.<BR><BR>Pål

  2. #2
    Franco Guest

    Default RE: Query Trouble

    Pål<BR><BR>Try re-formatting the date sans fullstops eg convert the date to another format or pull it apart using day, month and year functions then put it back using concatenation.<BR><BR>Just an idea.<BR><BR>Franco

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts