I have a header record with values for weight and value - joined to a detail file with weight values only which i need to use to allow me to exclude certain product types etc. from the document using various selections and to aportion the total value across the weights.
My problem is that i need to be able to display the information in a pivot table using a combination of the detail records and header records.
using left join and group by to join to the header file means the values in the header file are repeated and sum(value) leaves me with the value multiplied by the number of rows of detail records.