Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

Not applicable

FieldIndex problem

Hello everyone

im having an issue regarding the use of FieldIndex and FieldValue functions.

im using the next expression:

FieldValue('Field2', FieldIndex('Field1',(sum(Venta)/1000)/(sum(Presupuesto)/1000+sum(Ppto)/1000)))

if instead of  calculating the value to search i type it it works but i actually need to be calculated.

thanks in advance

1 Solution

Accepted Solutions
Not applicable

Re: FieldIndex problem

your expresion should look:

FieldIndex('AlcanceReal', floor((sum(Venta)/1000)/(sum(Presupuesto)/1000+sum(Ppto)/1000),0.001))

when you use num(....,'0,001') you only change the display format  

8 Replies
Not applicable

Re: FieldIndex problem

i'm not sure your expression gives always an integer value  - try to use a floor function

or

calculate the value outside the chart in a variable

and past it like:

FieldValue('Field2', FieldIndex('Field1',$(vNumber))

Not applicable

Re: FieldIndex problem

Thanks pari pari ive already try that and it works but it brings me the same value for al my table rows

sebastiandperei
Valued Contributor

Re: FieldIndex problem

Hola alfredo!

Estás seguro que Field1 tiene exactamente el valor que da la expresión?

Agregá otra expresión con (sum(Venta)/1000)/(sum(Presupuesto)/1000+sum(Ppto)/1000) y fijate si ese es el valor exacto que tiene el Field1.

Podés mandar una copia reducida?

Not applicable

Re: FieldIndex problem

Que tal sebastian,  si ya he verificado los numeros e incluso les he dado el mismo formato con la funcion num

En un momento mas subo un ejemplo

Not applicable

Re: FieldIndex problem

Here is an example im trying to get the  FieldIndex of the value in search in index column

Not applicable

Re: FieldIndex problem

your expresion should look:

FieldIndex('AlcanceReal', floor((sum(Venta)/1000)/(sum(Presupuesto)/1000+sum(Ppto)/1000),0.001))

when you use num(....,'0,001') you only change the display format  

Not applicable

Re: FieldIndex problem

Thanks Pari Pari but, with  floor it lowers me the result and i need the exact number with the 3 decimals

Not applicable

Re: FieldIndex problem

sorry i wrote it erong now it works thanks a lot pari pari

Community Browser