Tuesday, April 5, 2011

Get maximum value with Zend_Db_Table

Hi,

Ive got a Zend_Db_Table

Now I want to get the maximum available value of a field.

Is there a way to get the MAX(number) value or do I need to use basic SQL?

Thanks!

From stackoverflow
  • Use

    new Zend_Db_Expr('MAX(number)')
    

    as one of the fields in the Zend_Db_Table_Select.

    baklap : thanks! It's working

0 comments:

Post a Comment