Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
How do I set up a bar chart to only sum my 'Timereported' field for a week at a time? Then change when the new week begins.
Try a set identifier 1 in both set expressions, like
=count({ 1 <Date = {">=$(=weekstart(today(),-1))<=$(=weekend(today(),-1))"} >} distinct TechID)*40
That works to keep the selection regardless of user selection.
Thanks for all your help. You're very helpful as always!
Having a slight problem with the bar graph now.
I attached the .qvw again with the problem.
The bar chart should only be displaying 'target hours' for 'user group' that have distinct 'TechID's' and multiply by 40 hours.
So why does my bar chart have 'PS' labeled as 40 when if you go over to the Details tab, there are no 'PS' value in the UserGroup field?
Some of your Dates in table TimeLog2 are in fact timestamps and don't link to your calendar.
Use
daystart(TimeLogDate) as Date,
to create a date without a time part (maybe add a date() around for formatting).
Regards,
Stefan
This would be in the script?
Yes, do this in the load script (as a hint, as can only be used in the script). Just replace your TimeLog2 Load line
TimeLogDate as Date,
with
daystart(TimeLogDate) as Date,
or
date(daystart(TimeLogDate)) as Date,
That did not work. The 'PS' field is still showing up in the bar graph.
As an aside, you wouldn't happen to be able to help explain section access/ have a sample qvw that uses it?
Yeah, the PS field will probably still show up, but you see the details for the July 5th now, don't you?
Then please attach an updated file.
There is quite a nice document explaining section access in the docs section:
Aha! It seems to keep showing up because theres a value I had hidden on the details tab for July 5th that is null. How can I prevent it from being in the bar graph?
Not sure what your criterium to hide the record is, a NULL in TimeReportedActual for that date? You can consider only records that show a value in that field using something like
=count({<TimeReportedActual = {"*"}, Date = {">=$(=weekstart(today(),-1))<=$(=weekend(today(),-1))"},
Month=, Day=, Year=, Week=, Quarter=>} distinct(TechID))*40