Title: Sort Table By Date
Last modified: September 11, 2024

---

# Sort Table By Date

 *  Resolved [nishantoswal](https://wordpress.org/support/users/nishantoswal/)
 * (@nishantoswal)
 * [1 year, 9 months ago](https://wordpress.org/support/topic/sort-table-by-date/)
 * We have installed the tablepress extension sorting plugin but nothing seems to
   be working. Reffer to the canada recommendation table, we are trying to use sort
   table by date but its not working.
 * The sorting stops as soon as we add the following comand “columnDefs”: [ { “type”:“
   date-eu”, “targets”: [ 2 ] } ]
 * Can you please assist us. We want customers to sort by dates too in dd-mm-yyyy
   but its sorting like numbers
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fsort-table-by-date%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [1 year, 9 months ago](https://wordpress.org/support/topic/sort-table-by-date/#post-18007548)
 * Hi!
 * Thanks for your post and sorry for the trouble!
 * At this time, the date format `dd mmm yyyy` that you are using is not supported
   natively (it will be in the upcoming TablePress 3, currently scheduled for early
   November).
 * Therefore, I recommend using an approach like [https://wordpress.org/support/topic/date-order-6/](https://wordpress.org/support/topic/date-order-6/)
   where you add extra (hidden) columns with the date in `mm/dd/yyyy` format, used
   only for the sorting.
 * Regards,
   Tobias
 *  Thread Starter [nishantoswal](https://wordpress.org/support/users/nishantoswal/)
 * (@nishantoswal)
 * [1 year, 9 months ago](https://wordpress.org/support/topic/sort-table-by-date/#post-18007795)
 * Ok so i changed the date to mm/dd/yyyy But when we click on Buying date to sort,
   its giving random results. Is there a way we can get it correct. When anyone 
   click in there to sort they can sort with nearest date to farthest and viceversa
 *  Thread Starter [nishantoswal](https://wordpress.org/support/users/nishantoswal/)
 * (@nishantoswal)
 * [1 year, 9 months ago](https://wordpress.org/support/topic/sort-table-by-date/#post-18008020)
 * Hey it worked added a new coloum with s.no and then used this
 * “columnDefs”: [ { “orderData”: [ 2 ], “targets”: 3, visible: true }, {targets:
   2, visible: false}]
 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [1 year, 9 months ago](https://wordpress.org/support/topic/sort-table-by-date/#post-18008064)
 * Hi,
 * perfect! In the visible columns, you could now also go back to a format like `
   4 Jul 2024` if you prefer that format.
 * Best wishes,
   Tobias

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Sort Table By Date’ is closed to new replies.

 * ![](https://ps.w.org/tablepress/assets/icon.svg?rev=3192944)
 * [TablePress - Tables in WordPress made easy](https://wordpress.org/plugins/tablepress/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/tablepress/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/tablepress/)
 * [Active Topics](https://wordpress.org/support/plugin/tablepress/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/tablepress/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/tablepress/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * Last activity: [1 year, 9 months ago](https://wordpress.org/support/topic/sort-table-by-date/#post-18008064)
 * Status: resolved