ZF2-385: Sql\Select produces an incorrect sql query for predicates that contain '%' characters

Issue Type: Bug Created: 2012-07-03T07:53:45.000+0000 Last Updated: 2012-07-03T08:17:21.000+0000 Status: Resolved Fix version(s): Reporter: Yonni Mendes (yonman) Assignee: Martin Meredith (mez) Tags: - Zend\Db

  • Predicate
  • Sql\Select

Related issues: Attachments:


Steps: Create a Sql\Select object Add a string predicate through where('file_name like '%a') use getSqlString to retrieve the result

Expected SELECT * FROM


table> WHERE file_name like '%a'



table> WHERE '

If I remove the "%" character, everything works fine. Same result if I pass the predicate as an array


Posted by Martin Meredith (mez) on 2012-07-03T08:08:42.000+0000

Posted by Evan Coury ( on 2012-07-03T08:17:21.000+0000

This actually got merged as part of

Have you found an issue?

See the Overview section for more details.


© 2006-2018 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.