Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Data Modeling

I have Store And Sales tables

StoreArea
A100
B200

Store

ProductPriceDate
A11.25$18/01/2016
A22.25$19/01/2016
A33.25$18/01/2016
B11.25$19/01/2016
B22.25$20/01/2016

Select * from Store, Sales  where Store.Store= Sales.Store will Return

AreaStoreProductPriceDate
100A11.2518/01/2016
100A22.2519/01/2016
100A33.2518/01/2016
200B11.2519/01/2016
200B22.2520/01/2016

The Sum(Area) =700. How can i get Accurate Sum of Area in Qlikview?

How do we resolve this issue in Qlikview?

4 Replies
sunny_talwar

So intead of joining these two tables, you can keep them as separate tables, but connected on Store... Once you do that your Sum(Area) will give you 300 and there will be still an association between the two tables through Store field.

Anonymous
Not applicable
Author

Srikanth,

You should normalize your table in this scenario. Maintain data in separate tables.

Or
MVP
MVP

You've forgotten to tell us what the expected result is..

As long as you bring each table into your QlikView model individually - that is, select * from Store and select * from Sales (they will auto-join on Store because it is the same name in both tables), you should get 300 for sum(area). If you actually want 700, you need to pre-join the tables in your SQL, as you have in your example.

sureshsindhigi
Contributor III
Contributor III

Hi Srikanth,

As sunny Talwar mentioned, use the attached QVW file for the reference, Hope it will provide the solution which is looking for you.

Regards,

Suresh Sindhigi.