4 messages in com.mysql.lists.mysqlhelp please, patter matching problem
FromSent OnAttachments
Dan12 Jan 2002 06:48 
Roger Baklund12 Jan 2002 08:39 
Douglas Forrest12 Jan 2002 13:16 
Douglas Forrest12 Jan 2002 13:32 
Subject:help please, patter matching problem
From:Dan (dan@garbersoft.net)
Date:01/12/2002 06:48:45 AM
List:com.mysql.lists.mysql

mysql and Perl

Can someone tell me what's wrong with this code:

$sth=$dbh->prepare("SELECT Contacts FROM Info WHERE Name=?);

$sth->execute("%$sname%");

$dname = $sth->fetchrow_array;

$names is supposed to be a substring. So if I want to search for a middle name or just a first name or even a last name.

Any help is greately appreciated.