P
Peter
So powerful but sooooo frustrating.
In a Select query I have a calculated field that contains
LOS: DateDiff("d",[A_Date],[D_Date])
A_Date and D_Date are, in turn, calculated fields (they use left(), mid()
and right() to manipulate a table field from yyyymmdd (text data type) to
dd/mm/yyyy (still as text I assume).
When I run the query all looks fine. Then back in query design view I add a
criteria for example >1 or “1†in the criteria row in the LOS field. Now when
I run the query I get two “Enter Parameter Value†boxes prompting for A_Date
first and then D_Date. No matter what I enter the resultant query has just
one all blank record.
What is going on? Why the prompt for input?
I have tried replacing the two aliases A_Date & D_Date in the above
expression with the text manipulation functions. Still the query runs okay
but now I get a Data type mismatch error when I enter a criteria either text
eg "1" or a number eg 1.
Please accept my apologies if this has been answered before – I did look
quite hard.
I bet I’ve got something very basic wrong. Thanks for your help.
Peter
In a Select query I have a calculated field that contains
LOS: DateDiff("d",[A_Date],[D_Date])
A_Date and D_Date are, in turn, calculated fields (they use left(), mid()
and right() to manipulate a table field from yyyymmdd (text data type) to
dd/mm/yyyy (still as text I assume).
When I run the query all looks fine. Then back in query design view I add a
criteria for example >1 or “1†in the criteria row in the LOS field. Now when
I run the query I get two “Enter Parameter Value†boxes prompting for A_Date
first and then D_Date. No matter what I enter the resultant query has just
one all blank record.
What is going on? Why the prompt for input?
I have tried replacing the two aliases A_Date & D_Date in the above
expression with the text manipulation functions. Still the query runs okay
but now I get a Data type mismatch error when I enter a criteria either text
eg "1" or a number eg 1.
Please accept my apologies if this has been answered before – I did look
quite hard.
I bet I’ve got something very basic wrong. Thanks for your help.
Peter