Issues

ZF-7267: Oracle Adapter insert function adds quote to tablename and causes the query to throw (table/view not found) exception

Issue Type: Bug Created: 2009-07-14T10:24:18.000+0000 Last Updated: 2010-04-04T06:26:44.000+0000 Status: Resolved Fix version(s): Reporter: farhad abar (farhad.abar@gmail.com) Assignee: Mickael Perraud (mikaelkael) Tags: - Zend_Db_Adapter_Oracle

Related issues: Attachments:

Description

Oracle Adapter insert function adds quote to tablename and causes the query to throw (table/view not found) exception.

I am using Oracle Database Express Edition.

The following is the php statement in zend framework

    // build the statement
    $sql = "INSERT INTO "
         . $this->quoteIdentifier($table, true)
         . ' (' . implode(', ', $cols) . ') '
         . 'VALUES (' . implode(', ', $vals) . ')';

The function starts working once you change the above line to replacing $this->quoteIdentifier($table, true) with $table:

    // build the statement
    $sql = "INSERT INTO "
         . $table 
         . ' (' . implode(', ', $cols) . ') '
         . 'VALUES (' . implode(', ', $vals) . ')';

Comments

Posted by Mickael Perraud (mikaelkael) on 2009-07-15T01:25:18.000+0000

See autoQuoteIdentifier options in the manual.

Posted by Mickael Perraud (mikaelkael) on 2010-04-04T06:26:43.000+0000

Closed as not an issue

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