Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Good morning, please, i need some help on this.
How can i get, with a table of this kind of data:
| MARKET | STATE_NAME | Sum | 
| spain | Andalucia | 1 | 
| spain | Madrid | 3 | 
| spain | Valencia | 5 | 
| spain | Galicia | 7 | 
| portugal | Porto | 2 | 
| portugal | Lisboa | 1 | 
| portugal | Setubal | 2 | 
Obtein an objct table like this:
| STATE_NAME | Sum | 
| Andalucia | 1 | 
| Madrid | 3 | 
| Valencia | 5 | 
| Galicia | 7 | 
| portugal | 5 | 
Thanks a lot!
Belén
Hi,
Use the below calculated dimension in your chart.
=if(MARKET = 'spain', STATE_name,MARKET)
The easiest way it will be in your load script, do something like:
LOAD
MARKET,
STATE_NAME,
IF (MARKET = 'Portugal', 'Portugal', STATE_NAME) AS STATE_NAME_AUX
FROM yourfile...
and then use STATE_NAME_AUX as a dimension, and sum(yourvalue) as a expression.
Hope that helps.
Can you share your application or sample file?
Not fully understood your requirement from your question
What i want is to do it from the chart, in properties Dimension. As a calculated dimensión, if posible.
Thanks
 
Hi,
Use the below calculated dimension in your chart.
=if(MARKET = 'spain', STATE_name,MARKET)
Thanks Venugo, That fits with my problem.
Other question... it is possible, also with other file, ( also in the dimensión):
From this data:
MARKET  | STATE_NAME | Sum | Channel | 
| spain | Andalucia | 1 | C.C | 
| spain | Madrid | 3 | Other | 
| spain | Valencia | 5 | On line | 
| spain | Galicia | 7 | Other | 
| portugal | Porto | 2 | On line | 
| portugal | Lisboa | 1 | C.C | 
| portugal | Setubal | 2 | Other | 
Get a table object like this? Taking also On line and Portugal inside the table whith the state_name
| STATE_NAME | Sum | 
| Andalucia | 1 | 
| Madrid | 3 | 
| Galicia | 7 | 
| On line | 7 | 
| portugal | 3 | 
Thanks a lot!
Belén
Hi,
Try with below in your expression.
Sum({<Channel -= {'On line'}>}Sum)
Is not working.....
=if(MARKET = 'spain', STATE_name,MARKET) Sum({<Channel -= {'On line'}>}Sum)
all together?
 
Below should be in script
=if(MARKET = 'spain', STATE_name,MARKET as STATE_name
Below as table or chart expression.
Sum({<Channel -= {'On line'}>}Sum)
Hi,
Use Dimension as : =if(MARKET = 'spain', STATE_name,MARKET)
and Expression could be : Sum({<Channel -= {'On line'}>}Sum)