Igor,
you can't find attachment because of the merge of ptcuser into PTC community.
They are working to adjust broken links.
Anyway, take a look at this document Resource for reporting
In it you can find a lot of query builder.
About the use of sub select you can use one of this two articles from PTC support https://support.ptc.com/appserver/cs/view/case_solution.jsp?n=CS26781&lang=en
https://support.ptc.com/appserver/cs/view/solution.jsp?n=CS33305