"..it gives error otheriwse it is sorting by date"
No. As I already pointed out, it is not sorting by date at all. It only appears to be be working because your sample data happens to be ordered by date. Try re-arranging the lines in your sample data and you will see what I mean.
In reply to Re^3: Sorting a CSV file
by McDarren
in thread Sorting a CSV file
by farhan
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |