Re: [PHP-DB] Mysql PDO statement with params in HAVING problem

2013-06-28 Thread Tamara Temple
Alexander Pletnev wrote: > Hi everyone, im new here, so please correct me if i created or formated > topic incorrectly. > > I found a problem. I have a simple query for my needs: > > $stmt = $dbh->prepare("SELECT concat(first_name,' ',last_name) as > full_name,t.* FROM `specialists` `t`

Re: [PHP-DB] Mysql PDO statement with params in HAVING problem

2013-06-27 Thread Vinay Kannan
$stmt = $dbh->prepare("SELECT concat(first_name,' ',last_name) as full_name,t.* FROM `specialists` `t` HAVING full_name like '%:query%'"); How about '%:$query%' instead of '%:query%' ? Does that solve the problem? Thanks, On Thu, Jun 27, 2013 at 5:21 PM, Alexander Pletnev < pletnev.rusa...@gma

[PHP-DB] Mysql PDO statement with params in HAVING problem

2013-06-27 Thread Alexander Pletnev
Hi everyone, im new here, so please correct me if i created or formated topic incorrectly. I found a problem. I have a simple query for my needs: $stmt = $dbh->prepare("SELECT concat(first_name,' ',last_name) as full_name,t.* FROM `specialists` `t` HAVING full_name like '%john%'"); $s