PDA

View Full Version : Query


ABC123

M_Mowat
12-04-2002, 06:26 PM
I am still having problems with a query that asks for records using askc_first_number and >=var->askc_last_number. It returns the first number and all numbers in between but not the last number that was entered as part of the query. I tried the "between" in place of
= and it does the same thing. Any other suggestions?

MM

Melvin Davidson
12-05-2002, 06:29 AM
I'm guessing this has to do with a character field. If there
are trailing spaces, then the data in the field could be

"last_value___" (training spaces) but the var-askc_last_number
would be just "last_value" (no trailing spaces) so the last
record would not print.

BTW, the expression is backwards as you have written.
If you truly want values BETWEEN first and last, it should be:
>=var->askc_first_number and askc_last_number

elsewise, you get the opposite.