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

Announcements
Note: You may notice some temporary visual or styling issues in the Community. Our vendor is actively investigating.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

BASICS OF WRITING A SYNTAX

HI

PLEASE TELLL ME HOW TO WRITE AN EXPRESSION?

BASIC SYNTAX OF AN EXPRESSION??

FOR EXAMPLE

SUM({$<COLUMN1={A,B}>} COLOUMN2)

WHAT MUST BE USED AS COLUMN1 AND COLUMN2???

3 Replies
Not applicable
Author

Hi

Column1 is a filter.

Assume that Column1 contains Name as A,B,C,D,... and Column2 contains their respective salary as 100,200,300,400,...

Suppose I want to add salaries of only A and B then expression will be

SUM({<Column1={"A","B"}>}Column2)

Suppose I want to add salaries of all people excluding A and B then expression will be

SUM({<Column1 - ={"A","B"}>}Column2)

I hope this clarifies understanding.

jagan
Partner - Champion III
Partner - Champion III

Hi,

in the expression Column1 is a filter, which excludes all other values and considers only A and B for calculation, Column2 is the field which is been summed up.

For example

SUM({<Year={'2011','2012'}>} Sales)

The above expression calculates the sum of Sales for the years 2011 and 2012.

Hope this helps you.

Regards,

Jagan.

jagan
Partner - Champion III
Partner - Champion III

Hi,

Hope the URL helps you in creating and understanding the expressions

http://tools.qlikblog.at/SetAnalysisWizard/QlikView-SetAnalysis_Wizard_and_Generator.aspx?sa=

Regards,

Jagan.