RE: [PHP-DB] data format problem in MS Access
| From: | Richard Allsebrook | Date: | Fri, 07 Jul 2000 14:16:04 +0000 |
| Subject: | RE: [PHP-DB] data format problem in MS Access | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-942@lists.php.net to get a copy of this message | ||
Have you tried converting RaNumber to a string in the query:
e.g.
SELECT RANumber, DateCall, ProductType,
ModelNumber
FROM TabTest
WHERE CStr(RANumber) like '6280'
BTW, If you are not doing a wildcard search (Like '*6280*'), you will bet a
better performance using equates (WHERE RANumber=6280) and this will also
get around your problem.
Hope this helps...
_____
~ Richard Allsebrook ~
Applications Developer and Webmaster
Easysoft Limited, No3 The Embankment, Leeds, LS1 4BJ
http://www.easysoft.com <http://www.easysoft.com>
The Home of Data Access Middleware
"A computer lets you make more mistakes faster than any invention in human
history-with the possible exceptions of handguns and tequila."
_____
-----Original Message-----
From: Vojtěch Dvořák [mailto:vojtech_dvorak@servind.cz]
Sent: Friday, July 07, 2000 2:19 PM
To: php-db@lists.php.net
Subject: [PHP-DB] data format problem in MS Access
Hi,
I have a problem with very basic thing.
When I will use this statement: "SELECT RANumber, DateCall, ProductType,
ModelNumber
FROM TabTest
WHERE RANumber like '6280' "
Everything works fine if "RANumber" is in Text format in MS Access. When I
change "RANumber" to Number format it gives me this message: "ODBC Error:
22005: [Microsoft][ODBC Microsoft Access 97 Driver] Data type mismatch in
criteria expression."
Ok, I can change format type of this column in my database, but isn't there
any other solution?
Thanks
Vojtech
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net
For additional commands, e-mail: php-db-help@lists.php.net
To contact the list administrators, e-mail: php-list-admin@lists.php.net