Hi,

Using the DB profiler with your code I get the following results:

string(67) "SQLSTATE[HY093]: Invalid parameter number: no parameters were bound"

string(68) "Where clause: title = 'Tussendoortje: DSM\'s paraplumerk nu al 
lek?'"


No further select or insert SQL statements appear for the article. There were some other SQL statements logged for other articles without problems (it loops through a newsfeed), but these are unrelated. If you want I can mail those as well, though.

I also logged the value of $title:

string(43) "Tussendoortje: DSM's paraplumerk nu al lek?"

This is the correct title of the article.

Best regards,
Pieter

Bill Karwin schreef:
Would it be possible for you to show the value of $title, and the full SQL string produced by the fetchRow()? You can use the the Db Profiler to report the SQL that it tried to execute. Something like this: $sql = $db->quoteInto('title = ?', $title);
$db->getProfiler()->setEnabled(true);
try {
  $checkTitleExists = $newsItem->fetchRow($sql);
} catch (Zend_Exception $e) {
  Zend_Debug::dump($e->getMessage());
  Zend_Debug::dump("Where clause: $sql");
  foreach ($db->getProfiler()->getQueryProfiles() as $qp) {
    Zend_Debug::dump("SQL: " . $qp->getQuery());
  }
}
Regards,
Bill Karwin

    ------------------------------------------------------------------------
    *From:* Pieter v.d. Brink
    [mailto:[EMAIL PROTECTED]

    *The relevant lines of code are these two:
    $sql = $db->quoteInto('title = ?', $title);
    $checkTitleExists = $newsItem->fetchRow($sql);

    The article that is being retrieved is the following:
    
http://www.evmi.nl/nieuws/overig/4337/tussendoortje-dsm%27s-paraplumerk-nu-al-lek%3F.html

    Which comes from the RSS source: http://www.evmi.nl/rss/feed.xml

    I'm using a quite recent ZF snapshot (6493). But it has happened
    in an earlier stable release as well.
    I've also tried not using quoteInto, or doublequotes in the
    function, but it seems to occur regardless.

    Best regards,
    Pieter.


Reply via email to