8

I have lots of sheets describing different kind of expenses and gains of my small company, and I find no easy way to merge my tables like in this example I made:

Merging tables in Google Sheets goal

I want the last table to be auto filled with the lines of the others tables when I update them, so I can foresee the expenses and gain in time (by ordering the green table automatically by date ascending).

By now the only temp solution I found is to copy references to the other tables lines (yellow and blue) in the merging table (green) in advance.

Pivot tables do not permit to achieve this kind of gathering on several tables.

2
  • Why the excel tag? If you were using Excel then there may be A VBA solution. Excel 2013+ may allow a PowerPivot answer. Google Sheets don't implement either of those. Commented Dec 28, 2016 at 14:47
  • ok well, i am looking for a solution who would work in any calc software, but my preferences goes to libreoffice/openoffice/google sheets ;) i tagged excel to look for similar solutions in these Commented Dec 28, 2016 at 14:50

1 Answer 1

11

Use this Query formula in cell I2:

=QUERY({A2:C; E2:G}, "select * where Col1 is not null", 1)

To also order them by Date, add the order by:

=QUERY({A2:C; E2:G}, "select * where Col1 is not null order by Col1", 1)
Sign up to request clarification or add additional context in comments.

1 Comment

we are going somewhere with this, but i get a syntax error. i finally arrived to get something good with this QUERY function. like so: =QUERY({E2:G;A2:C}; "select * where Col1 is not null") thanhks!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.