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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Expression Help

Hi guys

In my attached dummy file, I am trying to count the number of invoices within a certain period.

However, I am getting the error "Error: Error in expression: '}' expected".

How do I resolve this? Could someone please have a look at the attached and advise?

Many thanks,

Gareth

17 Replies
Anonymous
Not applicable
Author

Thank you,

I'm getting closer!!

The expression is now returning 24,594 instead of 23,157 for Jan 2015.

Thanks,

Gareth

vishsaggi
Champion III
Champion III

Why it should be 23,157? Can you explain a little here please?

Anonymous
Not applicable
Author

Hi,

If you export the straight table and filter the date to just be Jan-2015, there are 23,157 records.

Thanks,

Gareth

marcus_malinow
Partner - Specialist III
Partner - Specialist III

Hi Gareth,

it might be useful here if you go into a bit more detail.

What are you trying to count here? Suppliers? Invoices?

What is the reason for your set analysis?

What is the relationship between Invoice Date and your Year and Month fields?

Marcus

Anonymous
Not applicable
Author

Hi Marcus,

Further information as requested:

What are you trying to count here? Suppliers? Invoices? For now, the number of invoices submitted within the selected range.

What is the reason for your set analysis? Advised this was the best way to do it, and if I decide to count the number of suppliers that have submitted an invoice in the set selection then it will be a relatively easy change in the expression.

What is the relationship between Invoice Date and your Year and Month fields? The Year and Month fields are derived from the Invoice Date field at the time of loading the data into the app.

Hope this helps,

Gareth

marcus_malinow
Partner - Specialist III
Partner - Specialist III

Hi Gareth,

What is the relationship between Invoice Date and your Year and Month fields? The Year and Month fields are derived from the Invoice Date field at the time of loading the data into the app.

In which case there may be an issue. Create a table box with Invoice Date, Year and Month.

A few example rows - Invoice Date here seems to bear no relation to Year and Month

Invoice Date Year Month
01/06/20132015Jan
08/10/20132015Jan
23/10/20132015Jan
07/11/20132015Jan
13/12/20132015Jan
22/12/20132015Jan
23/12/20132015Jan
24/12/20132015Jan
01/01/20142015Jan

Marcus

dinuwanbr
Creator III
Creator III

Hi,

PFA

Rgds,

Tharindu

Anonymous
Not applicable
Author

Thanks Marcus,

Yup, I think there was indeed a problem. Tried it all with different sample data and it works fine now.

Many thanks for your help,

Gareth