Formula from fields

Hi

I need a new column with formula 'NG Amount' / 'Component Qty' * 1000000

I tried to perform SCRIPTED FIELDS but without success.

Thanks for the helpers

Can you share what you tried with scripted fields?

I tried very simply
doc[‘component qty].value / doc[‘NG amount’].value

Anyone please?

Hi, can you please try https://github.com/fbaligand/kibana-enhanced-table, this plugin do mathematical caculations

Sorry for the delay. It seems like there are documents in your index that do not contain the fields you are working with here.

You can check with

if (doc['my-field-anme'].value != null)

and return a default value if it's not available.

hii
It gave me a result, but really wrong

I will try to explain what I want to do maybe there is another way.
I'm trying to do a division and multiplication operation for the formula.

(B / A) * 1000000

Try using tsvb.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.