Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
viveksingh
Creator III
Creator III

QlikSense-Add dummy value in Field and sum up the records

Hi Experts,

I have a data like below

NameSAL
ABC100
DEF200
GH50
IKJ10

now I want to add one dummy value under and I need to sum up the specified records under SAL

Like,

NameSAL
ABC100
DEF200

GROUP 1 SUM

300
GH50

GROUP 2 SUM

50

G1+G2 Sum

350

IKJ10

GROUP 3 sum

10

TOTAL360

In the above table GROUP 1 SUM is a dummy column which will sum SAL of ABC+DEF

I want to specify how many rows are need to be summed.

Thanks,

Vivek

5 Replies
kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

You can try below logic.

Data:

Load * inline [

Name, Group, SAL

ABC,Group1,100

DEF,Group1,200

GH,Group2,50

IKJ,Group3,10

];

FinalData:

Load Group as Name,Sum(SAL)  as SAL Resident Data Group by Group;

Concatenate(FinalData)

Load Name, SAL resident Data;

Concatenate(FinalData)

Load 'Total' as Name,Sum(SAL) as SAL Resident Data;

Drop table Data;

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
viveksingh
Creator III
Creator III
Author

Hi Kaushik,

I my table I don't have Group field. to group them.

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

HI,

That is something which you need to create to tell which values should be Grouped under what.

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
viveksingh
Creator III
Creator III
Author

Hi Kaushik,

Thanks for the reply.

you are correct but, It is the sample data which I posted. but in real time in have very huge data. I cannot create GROUP manually.

forget about the SUM, can we add A dummy field atleast?

Like GROUP 1 SUM in the above table

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

You can use the Mapping function to map it from other source.

Hope you know how to use the apply map.

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!