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

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Inter field calculations

Hello

i want to do inter field dividation . field1/field2 at sript level how could i do it ,pls give me suggestions

3 Replies
sushil353
Master II
Master II

it is simple:

tab1:

LOAD * INLINE [

field1,field2

1, 1

2, 3

3, 5

4, 7

]

;

tab2:

load *

,field1/field2 as field3

Resident tab1;

HTH

Sushil

Not applicable
Author

thank u shushil,

I have done same  in if condition but it did not shows result

if(cond=true,field1/field2) as sales   But it shows field1 in sales.

sushil353
Master II
Master II

Hi,

Below script is working for me

tab1:

Load * inline

[

field1,field2,cond

1, 2,T

2, 4,f

3, 9,T

];

tab2:

LOAD

if(cond='T',field1/field2) as test

Resident tab1;