I sometimes run into the same problem, especially with complex trusses.
As far as I know, there's no quick and simple way of doing it, but there are a couple ways to make it easier. Sadly, it seems like you can't select a subdomain in the subdomain mode and carry that selection to boundaries or edges (that would be a great feature).
As Ivan said, use (and abuse) groups. Normally, whenever I add geometry, I try to put it in groups as soon as I model them, and try to be very verbose about them.
Another good option is to use the boundary list in boundary settings. Get a feel of how COMSOL arranges them (basically, it starts at the origin and starts sweeping through the axes). Once you are comfortable with it, it can become a very powerful tool. It's been a lifesaver for me.
As far as I know, there's no quick and simple way of doing it, but there are a couple ways to make it easier. Sadly, it seems like you can't select a subdomain in the subdomain mode and carry that selection to boundaries or edges (that would be a great feature).
As Ivan said, use (and abuse) groups. Normally, whenever I add geometry, I try to put it in groups as soon as I model them, and try to be very verbose about them.
Another good option is to use the boundary list in boundary settings. Get a feel of how COMSOL arranges them (basically, it starts at the origin and starts sweeping through the axes). Once you are comfortable with it, it can become a very powerful tool. It's been a lifesaver for me.