Skip to content

Instantly share code, notes, and snippets.

@aderowbotham
Last active November 2, 2015 15:33
Show Gist options
  • Save aderowbotham/88d02339979ff8639a9e to your computer and use it in GitHub Desktop.
Save aderowbotham/88d02339979ff8639a9e to your computer and use it in GitHub Desktop.
Spreadsheet concatenation formulae

Spreadsheet concatenation formulae

These are tested in Open Office. May need modifying for Excel.

Combine multiple address fields into one

Contatenate cells B5 - F5, inserting a comma and line break, only if the cell is not blank

=IF(TRIM(LEN(B5));B5&","&CHAR(10);"")&IF(TRIM(LEN(C5));C5&","&CHAR(10);"")&IF(TRIM(LEN(D5));D5&","&CHAR(10);"")&IF(TRIM(LEN(E5));E5&","&CHAR(10);"")&IF(TRIM(LEN(F5));F5;"")

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment