Results 1 to 10 of 10

Thread: where is the syntax error?

Threaded View

  1. #1

    Thread Starter
    New Member
    Join Date
    Oct 2005
    Posts
    7

    where is the syntax error?

    Could anyone tell me what is wrong with my query syntax?

    code:

    strConditionDates = "(((Mission_Date >= #" & txtDate1 & "#) AND (Mission_Date <= #" & txtDate2 & "#)) AND (Mission_Code = " & Me.ListBoxMission_Code & "))"

    Set rstMissions = CurrentDb.OpenRecordset("select distinct FK_Mission_PK from [sql_équipage des missions] where ((FK_MISSION_PK is not null) AND " & strConditionDates)

    with the debugger strConditionDates takes the following value:

    "(((Mission_Date >= #2005-01-01#) AND (Mission_Date <= #2005-10-05#)) AND (Mission_Code = AI 165 C))"
    Attached Images Attached Images  

Posting Permissions

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



Click Here to Expand Forum to Full Width