In magento $this->setDefaultSort('position'); sorts the grid by 'position' column but in descending order. How can I change its sorting order to Ascending.

1 Answer 1


I got it by searching in Magento files.

use $this->setDefaultDir('ASC'); to set direction.

  • Feel free to accept your own answer, so that the question does not count as "unanswered" anymore Sep 2, 2015 at 12:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.