Adding to sort order

3 posts by 2 authors in: Forums > CMS Builder
Last Post: June 8, 2016   (RSS)

By tCote - June 8, 2016

On my listing page I have the default sort order to sort from date. In my listings I have a field named stock_number. How would I add this field to the present sort code so that it sorts by date first and then stock number? 

Thanks

list($listingRecords, $listingDetails) = getRecords(array(
'tableName' => 'listings',
'perPage' => '10',
'orderBy' => 'createdDate DESC'

By tCote - June 8, 2016

Thank you.