Not completely sure on your specific case but imagine you have an order and orderitems, with an association between them so that an Order can have multiple orderitems.
In a dataview display the order entity and then within this dataview add a listview that displays the orderitems over the association with the order. Make sure the listview is editable and you can set the quantity field in the orderitems.
I hope this provides you with some idea on how to solve your particular challenge.