# New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Contributor

## Use a values of a column already calculated

Hi all,

there is a way to use in a formula a value already calculate in another column ?

A               B               C

60            50               10

where C is A-B..

Since both in Column A e B there are big expression behind, and it will be really massive to calculate again for the column C,

there is some way to say in the expression for Column C -->  Column(A) - Column (B)

thanks for any helps

13 Replies
Esteemed Contributor III

## Re: Use a values of a column already calculated

store  A and B values in variable    do below

(vValue) - (vSale)

Esteemed Contributor

## Re: Use a values of a column already calculated

Sure thing,

If you have a table; with 3 columns,

C (column 3 ) could have as an èxpression:

column(1)-column(2)

Try it

Contributor

## Re: Use a values of a column already calculated

Doesn' t work like this...

Esteemed Contributor

## Re: Use a values of a column already calculated

Can u maybe share a screenshot of what u have? and what result you got using this?

Because it works for me:

Honored Contributor II

## Re: Use a values of a column already calculated

let's try using the below expression for column 3:

( column(1) ) - ( column(2) )

Contributor

## Re: Use a values of a column already calculated

this is my test, and doesn't work..

Contributor III

## Re: Use a values of a column already calculated

Hi Pasquale,

It doesn't look like you're closing your parentheses correctly.

Try:

(column(1)) - (column(2))

Thanks,

Simon

Contributor

## Re: Use a values of a column already calculated

Hi Simon,

unfortunately the issues is not this one.. I tried and nothing happens.

Are we sure that should work for both QS and QV?

I am using QS

Best

Contributor III

## Re: Use a values of a column already calculated

Hi Pasquale,

Have just had a play around with it, and as per the Qlik documentation, it doesn't work on dimension values, just measures.. Could that be the issue?

"Column() returns the value found in the column corresponding to ColumnNo in a straight table, disregarding dimensions. For example Column(2) returns the value of the second measure column."

https://help.qlik.com/en-US/sense/3.1/Subsystems/Hub/Content/ChartFunctions/InterRecordFunctions/col...

Thanks,

Simon