Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
leocattqv
Creator
Creator

Switching Axis..

Hi all,

I have a data structure in my load that looks something like this:

LocationbuisenessSales Percentage

USA

widgets25%
USAwhosits50%
Germanywidgets30%
Germanywhosits15%

I need a table that looks something like this:

BusinessUSAGermany

widges

25%30%
whosits50%15%

is there a way that I can adjust the data to do this?

5 Replies
anbu1984
Master III
Master III

LOad buiseness,MaxString(If(Location='USA',[Sales Percentage])) As USA,MaxString(If(Location='Germany',[Sales Percentage])) As Germany Group By buiseness;

Load * Inline [

Location,buiseness,Sales Percentage

USA,widgets,25%

USA,whosits,50%

Germany,widgets,30%

Germany,whosits,15% ];

sujeetsingh
Master III
Master III

Use Pivot table

Dimension 1 =Business

Dimension 2= Location

expression as sales percentage

sujeetsingh
Master III
Master III

If you want it to be in the script then follow the below thread

Convert raw to column Generic Load

alkesh_sharma
Creator III
Creator III

Please find the attached QVW for your reference

PrashantSangle

Hi,

Create Straight Table

use Dimension Business,

then 1 : Expression for USA= Sum({<Location={"USA"}>}Sales)

2 : Expression for Germany= Sum({<Location={"Germany"}>}Sales)

Or

Create Pivot Table

use dimesion 1 as Business

dimension 2 as Location

and expression as Sales

Then drag you second dimension to Horizontal from vertical

and go to presentation select always Fully Expanded

Regards

Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂