how to put arguments into contextual filters
There's a comment in that article down below with a code to import for D7 and Views 3.

If you import that code into your Views 3 and then study the Contextual Filters and the Relationships you should get a good idea on how to achieve this.