Google Sheets – Solving Problems with the QUERY Function

google sheets

I tried this formula:

=concatenate(query('Scheda Intervento'!C2:K14;"select SUM (K) where (F>= date '2013-01-01' and F <= date '2013-01-31' and C = '" & A2 &"')";0))

The result is right but it gives me:

sum
35 €

but I want to have

35 €

Best Answer

Use the following formula:

=INDEX(query('Scheda Intervento'!C2:K13;"select sum (K)
where (F >= date '2013-01-01' and F <= date '2013-01-31'
and C = '" & A2 &"')");2;1)

After that you can perform the CONCAT handling.