Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.
First time visiting? Here are some places to start:- Looking for a certain topic? Check out the categories filter or use Search (upper right).
- Need support? Ask a question to our Community Support category.
- Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
- Be respectful, on topic and if you see a problem, Flag it.
If you would like to contact our Community Manager personally, feel free to send a private message or an email.
Insight into queries?
traveler_hauptman
Member, OS Professional, Mentor, Developers Posts: 419 PRO
I feel like I'm not getting the query system. I get the basics. But then I see something like this:
export function evLength(context is Context, arg is map) returns ValueWithUnits
<snip>
var edges = qEntityFilter(arg.entities, EntityType.EDGE);
var ownedEdges = qOwnedByBody(arg.entities, EntityType.EDGE);
return @evLength(context, { "edges" : qUnion([edges, ownedEdges]) }) * meter;
and I get confused.
Why did qEntityFilter not capture the edges owned by entities, making the qUnion necessary?
Does qEntityFilter only work on things that are not owned?
0
Comments
I'm not sure if that makes it more or less clear...