Skip to main content

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
QlikWorld 2023, a live, in-person thrill ride. April 17 - 20, 2023, in Las Vegas! REGISTER TODAY
cancel
Showing results for 
Search instead for 
Did you mean: 
paulo_costa_ifp
Contributor II
Contributor II

How to get region totals

I have the following chart:

Pagamentos - Município - Meso - Micro.png

For example, CABEDELO belongs to MESOREGIAO='ZONA DA MATA PARAIBANA' and MICROREGIAO='JOAO PESSOA'. I would like to get totals for the corresponding MESOREGIAO and MICROREGIAO.  The expressions run fine only when I select a MESOREGIAO or MICROREGIAO. Here are the expressions:

SUM(total {<MESOREGIAO={'$(=MESOREGIAO)'},MICROREGIAO=,MUNICIPIO=>}[VALOR PAGTO])

SUM(total {<MICROREGIAO={'$(=MICROREGIAO)'},MESOREGIAO=,MUNICIPIO=>}[VALOR PAGTO])

How can I build these expressions without the need to filter these metadata?

Regards,

Paulo

1 Solution

Accepted Solutions
Anil_Babu_Samineni

Extremely Sorry !!! Not really understand still. My luck is

SUM(TOTAL <MESOREGIAO> {<MUNICIPIO=>}[VALOR PAGTO])

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)

View solution in original post

5 Replies
Anil_Babu_Samineni

Do you mean this?

SUM(TOTAL {<MICROREGIAO={'ZONA DA MATA PARAIBANA', 'JOAO PESSOA'},MUNICIPIO=>}[VALOR PAGTO])

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
paulo_costa_ifp
Contributor II
Contributor II
Author

No, Anil.

I would like to build the expression without the need to fix a constant for MICROREGIAO, MESOREGIAO. Based on MUNICIPIO , it would consider totals only for the  corresponding MESOREGIAO and MICROREGIAO, in separate columns.

Do you understand what I mean?

Regards,

Paulo

Anil_Babu_Samineni

But, Field = Field ??? What you are going to try here? My assumption is this?

SUM(TOTAL {<MICROREGIAO={"=CABEDELO = MICROREGIAO"},MUNICIPIO=>}[VALOR PAGTO])

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
paulo_costa_ifp
Contributor II
Contributor II
Author

My expression is wrong, I know. As MUNICIPIO appears in one line, how could I know (dinamically) the total for the corresponding MICROREGIAO and MESOREGIAO (two new columns).

Do you understand me?

Anil_Babu_Samineni

Extremely Sorry !!! Not really understand still. My luck is

SUM(TOTAL <MESOREGIAO> {<MUNICIPIO=>}[VALOR PAGTO])

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)