How to rearrange rows and columns of text into one column

I would like to take a very large set of rows and columns of cells and rearrange them as one long column. is that possible with a formula?

From this

enter image description here

to this

enter image description here


Solution 1:

use this:

=QUERY(FLATTEN(D:G); "where Col1 is not null"; )