View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Jamie Collins Jamie Collins is offline
external usenet poster
 
Posts: 593
Default Pivot Table, Consolidating Columns

(Melanie) wrote ...

I have some Pivot tables which get their data from an external
database, the table brings back 4 columns 2 fat results and 2 Solid
results

No.Fat-Average Fat-Average-Retest T.S.-Average T.S.-Average-Retest
1 5.125 22.665
2 5.02 22.555
3 5.05 23.37
4 5.175 22.7

What I want to do is only have one column for each result (one for
fat, one for solids)


You may be able to achieve the desired result with the UNION keyword e.g.

SELECT
[Fat-Average] AS Fat,
[T.S.-Average] AS Solid
FROM Table1
UNION
SELECT
[Fat-Average-Retest] AS Fat,
[T.S.-Average-Retest] AS Solid
FROM Table2
;

Jamie.

--