I have a problem.
I programmed a query to check whether a database field containing a year value (typ varchar(4)) is within a given intervals. The script is like that:
$sqlAB=“SELECT …, year FROM …
WHERE
…
AND year >= ‘$txYearFrom’
AND year <= ‘$txYearTo’
AND …
order by …”;
$txYearFrom … To are a text strings which I read out from input fields like that:
The query result is sometimes wrong. How can I fix that and get reliable results?
Btw the database structure can not be changed…
Thanks all for a good idea…
Adriano
[email protected]