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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
mayuranp
Creator
Creator

Expression Help

Here is a simplified task I am facing now.

Lets say we have two tables in the datamodel.

Table1: Items

Item NoDescriptionStock
A001Candle

100

A002Cleanser50
C001Candle Component40
C002Cleanser Component 120
C003Cleanser Component 2

10

Table2: ItemComponents

Item No

Component Item No

A001C001
A002C002
A002C003

Items are made of component items.

Now, I want to create a straight table like below in Qlikview:

Item NoComponent Item NoItem StockComponent Stock
A001C00110040
A002C0025020
A002C00350

10

Can I write an expression to get the component stock in this straight table without making changes to the data model?

Thanks.

1 Reply
sasiparupudi1
Master III
Master III

May be

Aggr(Max(Stock) ,[Item No]) for Item Stock

and

Max({1<[Item No]={"$(=Max([Component Item No]))"}>}Stock)