Unpivot Command
738291Feb 25 2010 — edited Feb 26 2010I am trying to unpivot these columns using the "unpivot" command. the command works, but the only value returned is that of the first column in the "IN" clause:
select * from DEMAND_FACTS_LOAD
UNPIVOT
(Measure_Amts for Measures IN (
ELE_FUEL_CONSUMPTION,
NET_GENERATION_MWH,
IND_FUEL_CONSUPMTION,
TOTAL_FUEL_CONSUMPTION,
AVG_NET_GENERATION_MWH,
ELECTRIC_MMBTU
))
All of the columns are numeric and only the first column - FUEL_CONSUMPTION - returns its values unpivoted. The remaining columns (unpivoted rows) do not pivot! The other columns to be pivoted all contain numeric data in them. Any insight would be appreciated.