Query Question

  • Thread starter Thread starter Bill
  • Start date Start date
B

Bill

I have the following in Criteria: Between [StartingDate] And
DateAdd("d",[How Many Days],[StartingDate])
When I run the Query I have to enter the Data twice. What I’m doing wrong?
Thanks to anyone who can point out my error. I know it has to something
simple that I’m missing.
Thanks,
Bill
 
Bill said:
I have the following in Criteria: Between [StartingDate] And
DateAdd("d",[How Many Days],[StartingDate])
When I run the Query I have to enter the Data twice. What I’m doing wrong?
Thanks to anyone who can point out my error. I know it has to something
simple that I’m missing.


What do you get prompted for twice? My guess would be that you have spelled
it slightly differently in different places.
 
Bill said:
I have to enter "How mnay days" & "Starting Date". Don't know why.

You have to enter both of them twice? Please post the SQL View of the
query.
 
I have to enter "How mnay days" & "Starting Date". Don't know why.
Thanks,
Bill

Bill said:
I have the following in Criteria: Between [StartingDate] And
DateAdd("d",[How Many Days],[StartingDate])
When I run the Query I have to enter the Data twice. What I’m doing wrong?
Thanks to anyone who can point out my error. I know it has to something
simple that I’m missing.
Thanks,
Bill

Ummm...

That's exactly what you're asking for. You have one parameter [How Many Days]
and another parameter [StartingDate]. Access is asking you for both of them.

What do you expect? If you're asking for each parameter twice, perhaps you
could post the SQL view of the entire query.
 
Here is the SQL. I may be nuts but ,I think it works fine for one try. Then
it does not.
Thanks,
Bill

SELECT AllNumbers_Dly.drwDate , AllNumbers_Dly. drwGame ,
AllNumbers_Dly. drwNumbersOne , AllNumbers_Dly. drwNumbersTwo ,
AllNumbers_Dly. drwNumbersThree
FROM AllNumbers_Dly
WHERE (((AllNumbers_Dly.drwDate ) Between [StartingDate] And
DateAdd(("d"),[How Many Days],[StartingDate])))
ORDER BY AllNumbers_Dly.drwDate DESC , AllNumbers_Dly. drwNumbersOne DESC;


John W. Vinson said:
I have to enter "How mnay days" & "Starting Date". Don't know why.
Thanks,
Bill

Bill said:
I have the following in Criteria: Between [StartingDate] And
DateAdd("d",[How Many Days],[StartingDate])
When I run the Query I have to enter the Data twice. What I’m doing wrong?
Thanks to anyone who can point out my error. I know it has to something
simple that I’m missing.
Thanks,
Bill

Ummm...

That's exactly what you're asking for. You have one parameter [How Many Days]
and another parameter [StartingDate]. Access is asking you for both of them.

What do you expect? If you're asking for each parameter twice, perhaps you
could post the SQL view of the entire query.
 
Here is the SQL. I may be nuts but ,I think it works fine for one try. Then
it does not.
Thanks,
Bill

SELECT AllNumbers_Dly.drwDate , AllNumbers_Dly. drwGame ,
AllNumbers_Dly. drwNumbersOne , AllNumbers_Dly. drwNumbersTwo ,
AllNumbers_Dly. drwNumbersThree
FROM AllNumbers_Dly
WHERE (((AllNumbers_Dly.drwDate ) Between [StartingDate] And
DateAdd(("d"),[How Many Days],[StartingDate])))
ORDER BY AllNumbers_Dly.drwDate DESC , AllNumbers_Dly. drwNumbersOne DESC;

What prompts do you get, in what order?
In what way does it "not work" on the second try? The second time you open the
query or what? Do you get no results, wrong results, an error message?
 
Bill said:
Here is the SQL. I may be nuts but ,I think it works fine for one try.
Then
it does not.
Thanks,
Bill

SELECT AllNumbers_Dly.drwDate , AllNumbers_Dly. drwGame ,
AllNumbers_Dly. drwNumbersOne , AllNumbers_Dly. drwNumbersTwo ,
AllNumbers_Dly. drwNumbersThree
FROM AllNumbers_Dly
WHERE (((AllNumbers_Dly.drwDate ) Between [StartingDate] And
DateAdd(("d"),[How Many Days],[StartingDate])))
ORDER BY AllNumbers_Dly.drwDate DESC , AllNumbers_Dly. drwNumbersOne
DESC;


Is AllNumbers_Dly a table or a query? If it's a query, what is the SQL of
the query?
 
Back
Top