I've got an h:commandLink as follows:
<h:commandLink action="#{something.doAction(entity)}"> Go </h:commandLink>
<rich:dataTable value="#{query.resultList}" var="entity"> <snip/> </rich:dataTable>
You can't - thats the way JSF works. Design your app accordingly.