I have a stored procedure, called "myprocedure". How can I call it from Magento?
I tried:
$resource = Mage::getSingleton('core/resource');
$readConnection = $resource->getConnection('core_read');
$query = 'CALL myprocedure()';
$results = $readConnection->fetchAll($query);
var_dump($results);
This gives me a PDO error, whats wrong?
Thanks!
$readConnection->exec($query)
instead offetchAll