[Solar-talk] Disturbing Solar_Sql_Select problem

Rodrigo Moraes rodrigo.moraes at gmail.com
Sun Feb 25 10:30:03 PST 2007


On 2/25/07, Paul M Jones wrote:
> Which version of PHP?  There are some (quite drastic) differences in
> binding between PHP 5.2.0 and 5.2.1 that I've addressed in the
> "model" branch and will bring back to "trunk" soon.  Will explain
> more at that time.

Hmm. I'm using 5.2.1 since last week and wasn't aware of the drastic
differences. During this week I saw this exception other times, so ah,
it was the upgrade that caused it.

When I switched back to PHP 5.2.0, no exceptions were thrown after
several tries.

> Also, if you try it directly with a PDO object proper, does it throw
> the same exception?

It seems that no. I tried this and it works fine every time (5.2.0 and 5.2.1):

    $stmt = "SELECT games_game.* FROM games_game WHERE title = ? LIMIT 1";
    $obj = Solar::registry('sql')->getPdo()->prepare($stmt);
    $obj->execute(array('TONY HAWK\'s PROJECT 8'));
    $res = $obj->fetch(PDO::FETCH_ASSOC);
    var_dump($res);

Thanks for the quick response! I'll stay with PHP 5.2.0 until I
understand what is causing this.

rodrigo


More information about the solar-talk mailing list