Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I loaded a table from Excel file which looks like:
Company 2008 2009 2010 2011
ABC 10 20 5 3
CDE 5 10 3 2
Data:
CrossTable(year, Data)
LOAD Company,
2008,
2009,
2010,
2011
FROM
(biff, embedded labels, table is [revenue& Ops$]);
When I applied Cross table from the Edit script. I was able to see the values right. but after loading it and trying to use it in the qvw..it shows me the
both fields Years and Data with the value of the years
Years Data
2008 2008
2009 2009
2010 2010
2011 2011
Any Idea or help?
Thxs,
Hi,
this happens because QlikView generates the load script without the brackets in the field names making them constant values "2008", "2009" for all the rows. Try with the brackets, like this:
Data:
CrossTable(year, Data)
LOAD Company,
[2008],
[2009],
[2010],
[2011]
FROM
(biff, embedded labels, table is [revenue& Ops$]);
Regards,
Cesar
Like this?
Kiran.
Hi,
this happens because QlikView generates the load script without the brackets in the field names making them constant values "2008", "2009" for all the rows. Try with the brackets, like this:
Data:
CrossTable(year, Data)
LOAD Company,
[2008],
[2009],
[2010],
[2011]
FROM
(biff, embedded labels, table is [revenue& Ops$]);
Regards,
Cesar
Try this one as well:
Directory
;
CrossTable(Year, Data, 1)
LOAD *
FROM
[..\Documents\QlikView\Tutorial\TestCross.xlsx]
(ooxml, embedded labels, table is Sheet1);
perfect. all the above helped.
Thxs,