fixed automatic ordering when no order is specified