close

I have attached a excel file
can someone tell me how i can sort the middel collum from old date to
new date -------------------------------------------------------------------
|Filename: sortingdates.zip |
|Download: www.excelforum.com/attachment.php?postid=4512 |
-------------------------------------------------------------------

--
derksj
------------------------------------------------------------------------
derksj's Profile: www.excelforum.com/member.php...foamp;userid=3101
View this thread: www.excelforum.com/showthread...hreadid=525608
I have looked at your spreadsheet but am unclear what you want. Do you
wish to sort by period first, then date, or do you wish to change the
date format?--
robert111
------------------------------------------------------------------------
robert111's Profile: www.excelforum.com/member.php...oamp;userid=31996
View this thread: www.excelforum.com/showthread...hreadid=525608
Hi,
There are probably better ways of doing this but the below works by
creating a quot;helper columnquot;.

1) Create a lookup table for Months somewhere out of the way eg
January, February, etc in cells down a column amp; enter 1,2,etc in the
column to the right. (I used cells E2 to F13 in may example)

2) Enter the below formula into cell D2 amp; copy it down for as many rows
as needed:

=DATE(RIGHT(B2,5),VLOOKUP(MID(B2,FIND(quot; quot;,B2,FIND(quot;
quot;,B2,1) 1) 1,(LEN(B2)-5)-FIND(quot; quot;,B2,FIND(quot;
quot;,B2,1) 1)),$E$2:$F$13,2,FALSE),MID(B2,FIND(quot; quot;,B2,1),FIND(quot;
quot;,B2,FIND(quot; quot;,B2,1) 1)-FIND(quot; quot;,B2,1)))

3) Format column D as you want it, select all data amp; sort by column D.

I created this formula by developing the month, day, amp; year formulae
separately and then merging them into one larger formula. You will need
to change quot;$E$2:$F$13quot; if your lookup table is in a different location
to mine.

Hth
Rob Brockett
NZ
Always learning amp; the best way to learn is the experience...--
broro183
------------------------------------------------------------------------
broro183's Profile: www.excelforum.com/member.php...oamp;userid=30068
View this thread: www.excelforum.com/showthread...hreadid=525608
hi

I want to sort the datum collum (the middle collum)
ofcourse the other collums must change when the sorting takes place

greetings Jurgen--
derksj
------------------------------------------------------------------------
derksj's Profile: www.excelforum.com/member.php...foamp;userid=3101
View this thread: www.excelforum.com/showthread...hreadid=525608
Now I understand

in one cell put =search(quot;yquot;,yourcellreference) 2 (say it is in cell
T2)

this finds the position of the letter y and adds 2 to it

in another cell put =mid(yourcellreference,T2,50)

this gives you the date but in text format (say it is in cell U2)

in another cell put =value(U2) and format this cell to the required
date format

copy paste special values to all these new dates and delete the other
columns, give the new column a heading and now sort as normal.--
robert111
------------------------------------------------------------------------
robert111's Profile: www.excelforum.com/member.php...oamp;userid=31996
View this thread: www.excelforum.com/showthread...hreadid=525608

arrow
arrow
    全站熱搜
    創作者介紹
    創作者 software 的頭像
    software

    software

    software 發表在 痞客邦 留言(0) 人氣()