original_string: private function _formatOrder()
      {
          $orders = array();
  
          if (isset($this->_order[DbInterface::ORDER_RAND])) {
              $orders[] = 'RAND()';
          } else {
              foreach ($this->_order as $field => $order) {
                  $orders[] = "`$field` $order";
              }
          }
  
          return ' ORDER BY ' . implode(', ', $orders);
      }
code: private function _formatOrder()
      {
          $orders = array();
  
          if (isset($this->_order[DbInterface::ORDER_RAND])) {
              $orders[] = 'RAND()';
          } else {
              foreach ($this->_order as $field => $order) {
                  $orders[] = "`$field` $order";
              }
          }
  
          return ' ORDER BY ' . implode(', ', $orders);
      }
code_tokens: private function _formatOrder ( ) { $ orders = array ( ) ; if ( isset ( $ this -> _order [ DbInterface :: ORDER_RAND ] ) ) { $ orders [ ] = 'RAND()' ; } else { foreach ( $ this -> _order as $ field => $ order ) { $ orders [ ] = "`$field` $order" ; } } return ' ORDER BY ' . implode ( ', ' , $ orders ) ; }
docstring: Format the order fields to be included into the query.
  
  @return string
docstring_tokens: Format the order fields to be included into the query .