Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I would like to transform a table that will be loaded in from SQL. Is it possible to PIVOT this table in the 'Edit Script' statement, just like I would in SQL??
Thank You
Hi,
Could you post a sample doc to get a clear idea??
We can pivot using cross tables/generic loads in edit script!!
Kiru
Please write and explain better your idea or what you want to do?
if will be easier to us to help you
thank you
Fernando
So in this example it would be UNPIVOTing data. Here tblRpt_US_CDFBP_SalesEffectiveness_MonthlyTrends has a column for M1, another columns for M2, and so on...and here i am JOINing on the 'Label' column in tblCfgDynamicLabels
SELECT
various columns
FROM
( SELECT * FROM tblRpt_US_CDFBP_SalesEffectiveness_MonthlyTrends WITH
) p
UNPIVOT
(y FOR numDay IN (M1, M2, M3, M4, M5, M6, M7, M8, M9, M10, M11, M12) )unpvt
INNER JOIN
--select * from
tblCfgDynamicLabels lbl
ON unpvt.numDay = lbl.Label
ORDER BY categoryorder DESC
I hope that this is helpful