Hytham Shehab wrote:

> (2) sorting order is passed as a bind parameter:
> $sort = 'asc';
> $sth = $dbh->prepare("select student_name from students order by first_name
> $sort");
> $sth->execute($sort);


you're trying to substitute the value twice.  try something like this 
instead:

$sort = 'first_name asc';
$sth = $dbh->prepare("select foo from bar order by ?")
$sth->execute($sort);


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to