Home > Enterprise >  Sheets Merge Multiple Rows into 1 Row
Sheets Merge Multiple Rows into 1 Row

Time:12-09

I have multiple rows, each containing cells that do not overlap and I want to easily merge them into a single row with a formula. Bonus if I can also fill in the empty cells with something. In this case the text "off". All in a single formula.

enter image description here

CodePudding user response:

try:

=INDEX(TRIM(QUERY(B2:H7;;9^9)))

and:

=INDEX(IF(TRIM(QUERY(B2:H7;;9^9))=""; "off"; TRIM(QUERY(B2:H7;;9^9)))
  • Related