Guest User

Untitled

a guest
May 28th, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. ##index.php
  2. Doctrine_Query::create()
  3. ->from('Albums')
  4. ->fetchArray();
  5.  
  6. Doctrine::getTable('Albums')->getPriceid(3);
  7.  
  8. ##Albums.php
  9. class AlbumsTable extends Doctrine_Table
  10. {
  11. public function getPriceid($albumid)
  12. {
  13. $q = Doctrine_Query::create()
  14. ->select('a.priceid')
  15. ->from('Albums a')
  16. ->where('a.id=?',$albumid)
  17. ->limit(1)
  18. ->fetchArray();
  19. }
  20. }
Add Comment
Please, Sign In to add comment