Get quantity of some Components shipped

SOLVED

Hello,

I'm trying to use MS Query to get quantity of some Components shipped to each country in past years.

I am able to get such list of data for Items using tables of AR_InvoiceHistoryHeader/Detail. How can I get to quantity of Component then? I assume I need to access the table of BM_BillHeader/Detail but wondering how can join them with AR_InvoiceHistoryHeader/Detail taking into consideration of the Revision field of BM. Would someone please give me advice?

Thanks,

Haibo