Magento constructs its SQL queries like
$this->getSelect()->joinInner(
array('sbao' => $this->getTable('sales/billing_agreement_order')),
'main_table.entity_id = sbao.order_id',
array()
)
Is there a way to display the resulting query in a string format rather than printing out the huge object e.g.
echo $this->getSelect()->joinInner(
array('sbao' => $this->getTable('sales/billing_agreement_order')),
'main_table.entity_id = sbao.order_id',
array()
)->toString();