JOHN said:
I have a user prompted input that I need to compare in two
statments on the same query, is it possible to assign the
user prompted value to a variable then check the variable
against two differerent functions
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
The "user-prompted input" acts like a variable. E.g.:
PARAMETERS [What Month] INTEGER;
SELECT DateAdd("m", -[What Month], Date()) As BeginDate,
DateColumn As Last Date
FROM TableName
WHERE DateColumn Between DateAdd("m" , -[What Month], Date())
And Date()
If the user entered 3 at the [What Month] prompt the BeginDate will be 3
months prior to the current date.
You can use the prompt input as any valid variable is used.
--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)
-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv
iQA/AwUBQHXjU4echKqOuFEgEQLWhACg6dv30A4cyEiw5bb0+OQJp5wGW/oAn3yv
2inR+6vXbqXevpKGrcrKoTd8
=0eoc
-----END PGP SIGNATURE-----