BadFish523
Board Regular
- Joined
- Feb 15, 2018
- Messages
- 56
=IF(A2="Work Instructions",QUERY(Data!A2:N,<wbr>"select D where E='"&C2&"' and F='"&E2&"'"),IF(A2="Standard Work",QUERY(Data!A2:N,"select D where H='"&C2&"' and I='"&E2&"')")))
I'm trying to build a query that can be manipulated a little bit. What I want is for it to query (sheet'Data') columns e and f when box A2 says Work Instructions but I want it to query columns (sheet 'Data') h and i when box A2 says Standard Work. Anybody know how to do this?
Edit: Forgot to add the first part of the query works fine. Only when I change A2 to Standard Work does it not work.
I'm trying to build a query that can be manipulated a little bit. What I want is for it to query (sheet'Data') columns e and f when box A2 says Work Instructions but I want it to query columns (sheet 'Data') h and i when box A2 says Standard Work. Anybody know how to do this?
Edit: Forgot to add the first part of the query works fine. Only when I change A2 to Standard Work does it not work.
Last edited: