Searching Between two dates via user inut

DeathByGir

New member
Local time
Today, 17:45
Joined
Mar 26, 2008
Messages
2
Hey all i need to search for all records found between two dates and all i have been able to find is code that has predefined dates were i need user input.

Here is an example of my code, i got syntax error:

SELECT Applicant_Loan_Info.Submission
FROM Applicant_Loan_Info
WHERE (((Applicant_Loan_Info.Submission) Between #((([Submission]))=[Starting Submission])# And #((([Submission]))=[Ending Submission]#));

And if there is something obviously stupid with it, go easy, new at this.

Thnx in advance
 
SELECT Applicant_Loan_Info.Submission
FROM Applicant_Loan_Info
WHERE Applicant_Loan_Info.Submission Between [Starting Submission] And [Ending Submission]

^
 
Perhaps this will help

>=[Forms]![Attempts]![1] And <=[Forms]![Attempts]![2]

I just took those from one of my query criteria.

Attempts is the name of the form and the [1] and [2] are unbound textbox names.

Thus the query uses the entries on the form for its criteria and so there is no need to go to Query/Design view to set the criteria
 
SELECT Applicant_Loan_Info.Submission
FROM Applicant_Loan_Info
WHERE (((Applicant_Loan_Info.Submission) Between [Starting Submission] And [Ending Submission]));
 
SELECT Applicant_Loan_Info.Submission
FROM Applicant_Loan_Info
WHERE Applicant_Loan_Info.Submission Between [Starting Submission] And [Ending Submission]

Worked perfectly, thnx alot
 

Users who are viewing this thread

Back
Top Bottom