$sql_core = Mage::getSingleton('core/resource')->getConnection('core_read');
$select = $sql_core->select()
->from('tablename', array('*')) // select * from tablename
->where('id=?',1); // where id =1
$rowsArray = $sql_core->fetchAll($select); // return all rows