Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Multiplying two fields in a expression!

Hi

Imagine if Date is there are as a dimension in line chart and I want some to have some below in the expression. Is it possible?


Sales * Count(ID) //Where Sales and ID are the fields.


I tried something same like above but it is not giving any value. Is there is anyother way of doing it please.

Hope some can help me out.

47 Replies
Not applicable
Author


Deepak Kurup wrote:
I think it should be Sum(Sales) * count(distinct ID)<div></div>


Thanks but it didn't work 😞

deepakk
Partner - Specialist III
Partner - Specialist III

hi Attitude,

It did work ?? or didnt work ??.. if it didnt work.. Then create two separate expression and check the values. and in third expression add column(1) * Column(2).

I think there might be an issue in the data model,

suniljain
Master
Master

pls Check whether link is perfect between this field.

can you post application with limited data ?.

Not applicable
Author

Have attached the sample now. Please check and let me know some solution.

suniljain
Master
Master

Dear

Pls check and Reply

Not applicable
Author


Sunil Jain wrote:
Pls check and Reply<div></div>


Give me some time. I will check and get back to you

Not applicable
Author

Why there is no data in the chart? Can you please check and let me know

deepakk
Partner - Specialist III
Partner - Specialist III

hi Attitude,

Just need a clarification. I goan through your data and I was finding it diffcult to understand the data.

you data looks like.

Field1 Field2 ID Year Month Sales

A X 1 2009 X3 6

A X 1 2009 S3 6

Now in the above case if you look the month is getting repeated twice.

As per you output you require only Sales as 6 for which you are writing in Expression Sales

and if we make Sum(Sales) the value becomes 12 which you said is wrong.

There is something wrong either in the data or in the way we are analyzing.

maneshkhottcpl
Partner - Creator III
Partner - Creator III

Hi,

I think u r not explaining the problem / situation correctly. This is not a big issue.

Then also u can try

=

sum(Distinct SALES)*Count(ID)

or



=

aggr(sum(Distinct SALES),ID)*Count(ID)



And revrt back , we are curious to see the solution.



Not applicable
Author

Hi Manesh

Got stuck with some issues. Thats why I couldn't respond to you properly. Will get back to you very soon.