Sorting a query Field by date

&orderby=date will return posts by their dates.

<?php query_posts('post_type=page&post_parent=2&posts_per_page=-1&orderby=date&order=ASC'); ?>

Replace first line with this to show post according to their date.

Reference – Passing variables to query_posts


Update –

To sort the posts as per custom field value, Here’s the new code.

   query_posts('post_type=post&posts_per_page=-1&orderby=meta_value&meta_key=next_open_day&order=ASC'); ?>

Note – The date should be saved in – YYYY-MM-DD format. However we can further convert that date into required format. E.g. –

<?php
$date = "2012/08/21"; 
list($y, $m, $d) = split("https://wordpress.stackexchange.com/", $date); 
$newdate = $d."https://wordpress.stackexchange.com/".$m."https://wordpress.stackexchange.com/".$y;
echo $newdate;
?>