Is there a way to do a complex query that excludes results with a certain code? Let's say I have three codes, code1, code2, and code3, and I want to see segments that are coded with code1 and code3, but NOT if they are also coded with code2? This is relatively simple logic but I don't see a way to do it.
0 Votes
Stine Rüger posted
7 months ago
AdminBest Answer
Hi Philip,
Thanks for reaching out, we are happy to help. You should be able to accomplish this using a complex coding query ("Analysis" > Complex coding query) and selecting the option for "If Outside" and setting the options as noted in the screenshot. The desired codes go in section A ( in this case code 1 and code 3) and the code you want to exclude goes in section B. You can also select a subset of documents in the Options section.
We hope this helps, but let us know if you have further questions.
0 Votes
3 Comments
Sorted by
Stine Rügerposted
7 months ago
AdminAnswer
Hi Philip,
Thanks for reaching out, we are happy to help. You should be able to accomplish this using a complex coding query ("Analysis" > Complex coding query) and selecting the option for "If Outside" and setting the options as noted in the screenshot. The desired codes go in section A ( in this case code 1 and code 3) and the code you want to exclude goes in section B. You can also select a subset of documents in the Options section.
We hope this helps, but let us know if you have further questions.
0 Votes
P
Philip. loringposted
7 months ago
Hi there. This almost works, but is backwards for my needs. It only allows one code in the B section and multiple in the A, but I would need the opposite. Here's a screen-shot. It allows me to exclude multiple (box A is for what to exclude) but box B only allows for one inclusion. so I can get all Code1s or Code3s that don't overlap with Code2, but I can't get segments that have Code1&Code3 but not code2. Am I missing something?
Thanks again
0 Votes
Stine Rügerposted
7 months ago
Admin
Hello,
Yes, that is possible. In MAXQDA, you can perform a complex segment search to create exactly this type of query.
Here's how to do it:
Activate the codes code2 in the "Code System".
Call the "Complex Coding Query" function.
In the function selection, choose the "Only this code" option.
Drag the codes code2 into the "A" area.
Drag the code code1 + 3 into the "B" area.
Then click "Start"
With these settings, you will get in the "Retrieved Segments" list only the segments that are coded with code1 and code3, but not with code2.
Is there a way to do a complex query that excludes results with a certain code? Let's say I have three codes, code1, code2, and code3, and I want to see segments that are coded with code1 and code3, but NOT if they are also coded with code2? This is relatively simple logic but I don't see a way to do it.
0 Votes
Stine Rüger posted 7 months ago Admin Best Answer
Hi Philip,
0 Votes
3 Comments
Stine Rüger posted 7 months ago Admin Answer
Hi Philip,
0 Votes
Philip. loring posted 7 months ago
Hi there. This almost works, but is backwards for my needs. It only allows one code in the B section and multiple in the A, but I would need the opposite. Here's a screen-shot. It allows me to exclude multiple (box A is for what to exclude) but box B only allows for one inclusion. so I can get all Code1s or Code3s that don't overlap with Code2, but I can't get segments that have Code1&Code3 but not code2. Am I missing something?
Thanks again
0 Votes
Stine Rüger posted 7 months ago Admin
Hello,
Yes, that is possible. In MAXQDA, you can perform a complex segment search to create exactly this type of query.
Here's how to do it:
With these settings, you will get in the "Retrieved Segments" list only the segments that are coded with code1 and code3, but not with code2.
Please let us know if this helps.
Best regards,
Stine
0 Votes
Login or Sign up to post a comment