I have a spreadsheet managing a list of groups in time slots. Imagine the below are cells:
0830-0845, Bob Hoskins, Jack Table, Phil Cup
0845-0900, Bob Hoskins, J
Assuming your data starts in A2. Parse your input as Fixed Width to isolate the -
and the first ,
. Select Text for the first and third columns. Format the sheet as General. In D2 put:
=IF(E1<>E2,"S",IF(E2<>E3,"F",""))
and copy down to suit.
Copy ColumnD, Paste Special, Values over the top and delete rows with blanks in Column D. In B2 put:
=IF(AND(D2="S",D3="F"),A2&"-"&C3,IF(D2="S",A2&"-"&C2,""))
and copy down to suit.
Copy ColumnB, Paste Special, Values over the top and delete rows with blanks in Column B. In A2 put =B2&", "&E2
and copy down to suit. Copy ColumnA, Paste Special, Values over the top.
Delete all but ColumnA.