* Dan
Can someone tell me what's wrong with this code:
$sth=$dbh-prepare(SELECT Contacts FROM Info WHERE Name=?);
$sth-execute(%$sname%);
You should use the LIKE operator:
Name LIKE %roger%
URL: http://www.mysql.com/doc/S/t/String_comparison_functions.html
--
Roger
No closing quotes in prepare.
Also, I've never seen code that's looks quite like that; this may be
cleaner:
$sth=$dbh-prepare(SELECT Contacts FROM Info WHERE Name=%$sname%);
$sth-execute();
- Original Message -
From: Dan [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Saturday,
: Re: help please, patter matching problem
No closing quotes in prepare.
Also, I've never seen code that's looks quite like that; this may be
cleaner:
$sth=$dbh-prepare(SELECT Contacts FROM Info WHERE Name=%$sname%);
$sth-execute();
- Original Message -
From: Dan [EMAIL