Skip to main content

Split a pasted log into rows and fields

Your goal: Turn a small literal pipe-delimited log into a rectangular report while keeping empty records, blank fields and leading zeroes.

Full task requirements

Enter one formula in G5. Split the text in A2 at | between fields and LF between records, normalizing CRLF pairs first. Preserve empty fields and records, spaces and text types. Pad shorter records with empty text to the widest record. An empty A2 returns No records. Up to eight records and three fields fit G5:I12; the exact result dimensions count.

Three records with a missing middle fieldChoose boundaries and output dimensions0 cells selected
The source exposes stored \r and \n so you can locate record boundaries and empty fields.
Click or drag source cells; selected cells change color Drag from selected cells to deselect.
#
1
2
Step 1 of 4

Choose boundaries and output dimensions

Select the source cells in the worksheet, then complete the choices below.

Rules for this step

Normalize CRLF to LF before splitting. A pipe separates fields and LF separates records. Empty fields and empty records remain; pad shorter rows with empty text to the widest row.

Output record count
Output field count
0 cells selected