Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

don't want distinct

Hi All,

Below is my data when iam doing sum(col1) it is missing last record (28800), how to count All values

these values are cumming from QVD

Col1Col2
Assignee252000
Assignee144000
Assignee115200
Assignee57600
Assignee28800
Assignee28800

It show's in qlikview  as below  , need same as above

Col1Col2
Assignee252000
Assignee144000
Assignee115200
Assignee57600
Assignee28800
Assignee-

Regards,

Nagesh

7 Replies
prat1507
Specialist
Specialist

Hi

You may have a problem with data load. Please check. I'm getting the desired results. PFA.

Regards

Pratyush

eromiyasimon
Creator II
Creator II

how can you sum col1 which is containing text value

attach sample QVW

vinieme12
Champion III
Champion III

can you post the app that demonstrates the problem? are you doing this with an inline table load?

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
rahulpawarb
Specialist III
Specialist III

Hello Nagesh,


You can apply Count function on Col1 as well as Col2; however, Sum function can only be applied on Numeric values.

As per my primary analysis, last record (28800) is not missing; it is there in application. 2nd last and last record have same values; due to this QlikView is interpreting it as single combination.


If you create the straight table with Col1 & Col2 as dimensions and Count(Col1) & Sum(Col2) then you will notice that last record is there. Refer attached sample application.


Also, to get distinct values you can make use of RowNo() or RecNo() function (refer below given sample script).


Data:

LOAD *,

RowNo() AS RowNo,

RecNo() AS RecNo;

LOAD * INLINE [

Col1, Col2

Assignee, 252000

Assignee, 144000

Assignee, 115200

Assignee, 57600

Assignee, 28800

Assignee, 28800

];


Regards!

Rahul

sdmech81
Specialist
Specialist

HI,

R u doing sum(col2)..It should give u desired result..

Plss attach sample qvw..

Sachin

Not applicable
Author

Hi Nagesh,

please share your sample application so that we will help to you.

Not applicable
Author

try like this

count(nodistinct col1)