Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
yadav_anil782
Creator II
Creator II

set analysis

Dear Community,

      i have  user login details in one table and when i'm putting  "user_name" in dimention and  "=count(DISTINCT(LOGIN_TIME))" , its showing 53 count in chart which is correct as well because user logined 53 times in a day so its showing correct value . now i wants to short count(1) for  hole day .

example if user logined 53 times in hole day  then  result should be short day wise and in result will be only (1) count and if user logined 30  days no metter how many times but result should be 30 . plz help if anyone cane do this

yearmonthdayLogin TimeDateUSER_IDUSER_NAME
2011May1116:23:435/11/20111453B_SHARMA
2011May1116:24:395/11/20111453B_SHARMA
2011May1117:20:125/11/20111453B_SHARMA
2011May1117:22:275/11/20111453B_SHARMA
2011May1117:23:415/11/20111453B_SHARMA
2011May1117:24:375/11/20111453B_SHARMA
2011May1117:25:105/11/20111453B_SHARMA
2011May1117:26:175/11/20111453B_SHARMA
2011May1117:27:285/11/20111453B_SHARMA
2011May1117:28:135/11/20111453B_SHARMA
2011May1117:29:015/11/20111453B_SHARMA
2011May1117:29:575/11/20111453B_SHARMA
2011May1117:30:365/11/20111453B_SHARMA
2011May1117:31:255/11/20111453B_SHARMA
2011May1117:32:095/11/20111453B_SHARMA
2011May1117:33:025/11/20111453B_SHARMA
2011May1117:33:395/11/20111453B_SHARMA
2011May1117:34:235/11/20111453B_SHARMA
2011May1117:35:095/11/20111453B_SHARMA
2011May1117:35:595/11/20111453B_SHARMA
2011May1117:36:455/11/20111453B_SHARMA
2011May1117:37:385/11/20111453B_SHARMA
2011May1117:38:185/11/20111453B_SHARMA
2011May1117:39:345/11/20111453B_SHARMA
2011May1117:40:115/11/20111453B_SHARMA
2011May1117:40:545/11/20111453B_SHARMA
2011May1117:41:335/11/20111453B_SHARMA
2011May1117:42:175/11/20111453B_SHARMA
2011May1117:42:555/11/20111453B_SHARMA
2011May1117:43:365/11/20111453B_SHARMA
2011May1117:44:245/11/20111453B_SHARMA
2011May1117:45:195/11/20111453B_SHARMA
2011May1117:46:165/11/20111453B_SHARMA
2011May1117:51:025/11/20111453B_SHARMA
2011May1117:52:075/11/20111453B_SHARMA
2011May1117:53:155/11/20111453B_SHARMA
2011May1117:54:275/11/20111453B_SHARMA
2011May1117:55:285/11/20111453B_SHARMA
2011May1117:56:445/11/20111453B_SHARMA
2011May1117:58:065/11/20111453B_SHARMA
2011May1117:59:135/11/20111453B_SHARMA
2011May1118:00:445/11/20111453B_SHARMA
2011May1118:02:135/11/20111453B_SHARMA
2011May1118:03:155/11/20111453B_SHARMA
2011May1118:04:185/11/20111453B_SHARMA
2011May1118:10:115/11/20111453B_SHARMA
2011May1118:11:225/11/20111453B_SHARMA
2011May1118:12:255/11/20111453B_SHARMA
2011May1118:14:245/11/20111453B_SHARMA
2011May1118:15:415/11/20111453B_SHARMA
2011May1118:17:315/11/20111453B_SHARMA
2011May1118:18:185/11/20111453B_SHARMA
2011May1118:21:245/11/20111453B_SHARMA
6 Replies
PrashantSangle

Hi,

try

Sum(aggr(count(distinct User_Name),day))

Regards

Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂
mayankraoka
Specialist
Specialist

Hi Anil,

You can aggr by day :

Aggr(count(DISTINCT(LOGIN_TIME)),day)


Regards,

Mayank

Anonymous
Not applicable

Hi Anil,

Try this: count(aggr(count(distinct User_Name),Date))


The Date field can be converted to a date in the script as:

UserLogin:

LOAD year,

     month,

     day,

     [Login Time],

     date#(Date) as Date,

     USER_ID,

     USER_NAME

FROM

Book1.xlsx

(ooxml, embedded labels, table is Sheet1);

Anonymous
Not applicable

If I am not wrong, suggestion by Max and Mayank would give you again same result what you are getting.

I wud say take User ID as Dim and expression would be count(distinct(day)).

Try this.

yadav_anil782
Creator II
Creator II
Author

Dear Balraj,

as per your logic result is  in attached

Anonymous
Not applicable

Could you share sample excel for same?