Issues

ZF-10642: Zend_Validate_Db_Abstract -> "Invalid bind-variable name" with mysqli adapter

Issue Type: Bug Created: 2010-11-04T09:16:18.000+0000 Last Updated: 2010-11-18T07:59:49.000+0000 Status: Resolved Fix version(s): - 1.11.1 (30/Nov/10)

Reporter: Artyom Shalaev (zeliret) Assignee: Ralph Schindler (ralph) Tags: - Zend_Validate

Related issues: Attachments: - ZF-10642.txt

Description

In 'getSelect' function 'field' parameter uses with ':value' replacement but Mysqli not support named parameters.

So validating throws exception 'Invalid bind-variable name'.

Version 1.11.0 $select->from($this->_table, array($this->_field), $this->_schema) ->where( $db->quoteIdentifier($this->_field, true).' = :value' );

Version 1.10.8 $select->from($this->_table, array($this->_field), $this->_schema) ->where($this->_adapter->quoteIdentifier($this->_field, true).' = ?', $value);

Comments

Posted by Ralph Schindler (ralph) on 2010-11-10T21:34:02.000+0000

Can you please try the attached patch? I think this should work in both named and positional parameters.

Posted by Ralph Schindler (ralph) on 2010-11-18T07:59:48.000+0000

FIxed in trunk at r23355 and in release branch 1.11 at 23356.

Have you found an issue?

See the Overview section for more details.

Copyright

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

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

Contacts