• Thanks a lot for your response Dwain. Your code is successful in keeping the families together and ordering the items by date as long as the parents have different dates. But when two or more parents have same date, it has failed in keeping the families together. It is ordering the parents with same date first and then their childs next.

    In our example, if we change the Item 5's date as '2012-08-07' (same as item 2) then the results are:

    ItemID Date

    2 2012-08-07 00:00:00.000

    5 2012-08-07 00:00:00.000

    1 2012-09-08 00:00:00.000

    3 2012-09-09 00:00:00.000

    4 2012-09-10 00:00:00.000