Skip to main content
Announcements
Qlik Connect 2025: 3 days of full immersion in data, analytics, and AI. May 13-15 | Orlando, FL: Learn More
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

1 chart two expression from different data sources

Hello,

Quick Question, I have two data sets that have nothing to do with each other and way different columns, but I want to use both in a stacked chart as percentages, I just want their result percentage values of each expression stacked on top of each other, so 1 chart ,two data sets, 2 expressions, stack the percentages on top of each other.  Qlikview charts wont let me becuase the dimension would only apply to one expression and not both, breaking the chart.

IS there some way to put a condition on a dimension to only apply to a particular expression?

I've done this before by creating 20+ variables for each situation on one data set, then and using those against the other data set in an expression, but that won't work in this case, way to many cases. 

Does any one know how to include two data sets in one bar chart, without breaking it due to the dimension not applying to both?

Thanks ahead of time

13 Replies
Not applicable
Author

I do not believe a dummy column would be possible, due to one data source is a sum off a spreadsheet, the other a sum out of a database, there isn't any type of relationship between the data, just trying to calculate each expression in percent, then stack them on top of each other, since they are so different a dummy column probably wouldn' work due to how they are aggregated differently.  Thanks though

Not applicable
Author

x axis would be current year and previous year, like 2014     2015,    for behavoir just looking for a stacked chart, one expression on top of the next, it would be easy if I had the same dimension for each data set but thats not possible here, due to them being data islands.  Thanks

ogster1974
Partner - Master II
Partner - Master II

why can't you create a field in each table call year and populate it with the relevant date?  Qlik would do the rest by adding year as your dimension you could stack as you want.

If they need to remain separated add a master calendar with year and have a field called tableayear and tablebyear in your other tables then use year as your dimension and in your expression include in set analysis tableayear=p(year) and in the other tablebyear=p(year)

Hope this helps

Regards

Andy

Not applicable
Author

Step1: in loading script, load the aggregated query like

Select year, sum(sales) from source1;

Step2: in the loading script load the aggregated query like

Select year,sum(sales) from source2;

Then they can be joined.

Right?

发自我的 iPhone

在 Aug 7, 2015,10:29 AM,Brad Estep <qcwebmaster@qlikview.com> 写道:

1 chart two expression from different data sources

reply from Brad Estep in App Development - View the full discussion

x axis would be current year and previous year, like 2014 2015, for behavoir just looking for a stacked chart, one expression on top of the next, it would be easy if I had the same dimension for each data set but thats not possible here, due to them being data islands. Thanks

Reply to this message by replying to this email, or go to the message on Qlik Community

Start a new discussion in App Development by email or at Qlik Community

Following 1 chart two expression from different data sources in these streams: Inbox

© 1993-2015 QlikTech International AB | Copyright & Trademarks | Privacy | Terms of Use | Software EULA