3

Not 100% sure how to explain this, feel free to edit this with more intelligent language.

I need to pull data from 2 tables in 1 sheet. Meaning, I need multiple query functions. Those query functions need to output vertically.

Both of my query functions work independently, but trying to combine them, only the first query function outputs.

Using this post as a guideline:

Query Multiple Ranges with Results in Row

I wrote this function

={QUERY(A3:B,"select A where B is null");QUERY(D3:F,"select D where(E='Yes' AND F is null)")}

My understanding is

={...} Creates an array that was explained as

The curly brackets {} are used when you want to access more than one thing, like you want to pull data from more than one tab sheet...

Source: https://productforums.google.com/forum/#!msg/docs/WOWhf-lGxmo/xsHQt4C2AQAJ

; should output vertically instead of horizontally.

My example sheet

https://docs.google.com/spreadsheets/d/1lZeBDsrfPrfFU_Aj6Em-3dvtav3K8k869cYx7vAazpo/edit?usp=sharing

(Images in case you don't want to click the link)

enter image description here The output that I get is just hello from Table 1 and nothing from Table 2, which should output with Foo appended after hello

How can I get the output from the 2nd query to show up?

4

The "problem" is that the formula is using open references so there are a lot of blank cells from Table 1 above the Foo value.

One way to avoid having a lot of blank cells is to filter them out:

={QUERY(A3:B,"select A where A is not null AND B is null");QUERY(D3:F,"select D where(E='Yes' AND F is null)")}

  • Oh jeez. I knew it was going to be something simple that I overlooked. Thank you! – Memj Apr 23 '18 at 4:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.