Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
amber2000
Creator
Creator

Expression on a time field failing

Hello everyone,

I'm having trouble again with an expression.

I would like to see which vendors deliver after 16:00 hrs, my timefield doesn't contain the : anymore.

In the load I've used the time function:

Time#([TI_End_Times],'hhmmss') AS [Rec_End_Time],

VendorIDRec_DateRec_End_TimeRec_Pallets
000B9522014101006133010
000B9142014101016151672

0000388

2014101017502455
00010872014101000000033
00014742014101015503920
0001524201410100323339

This is my expression:

= count({$<[Rec_End_Time]={">160000"}>}[Rec_Pallets])

Nothing is happening if I use that expression on this table, any idea what I'm doing wrong???

Kind regards,

Ambertje

1 Solution

Accepted Solutions
datagrrl
Creator III
Creator III

IF(Rec_End_Time>=0.6666607 and Rec_End_Time<=.75,Sum(Rec_Pallets))

View solution in original post

9 Replies
Gysbert_Wassenaar

You've only changed the display format to hhmmss. The actual value is still a time and thus a fraction of a day. So try testing for larger than 16/24: = count({$<[Rec_End_Time]={">0.666667"}>}[Rec_Pallets])


talk is cheap, supply exceeds demand
Anonymous
Not applicable

Hi,

if  you  need  to  show Rec_End_Time>=160000

try it

IF(Rec_End_Time>=160000,Rec_End_Time)

Ayuda 2.PNG.png

Regards!

amber2000
Creator
Creator
Author

Gysbert,

I've tried the expression but nothing is happening, no data is displayed.

Gysbert_Wassenaar

Can you post a document that demonstrates the problem?


talk is cheap, supply exceeds demand
amber2000
Creator
Creator
Author

Sorry Jannet

Not working in my straigth table, no results are shown.

datagrrl
Creator III
Creator III

I tried a few different things, and this worked to get the correct records to count:

if(Rec_End_Time>'16:00:00',1,0)

So this should work:

if(Rec_End_Time>'16:00:00',Rec_End_Time)

I tried using your set analysis expression and it worked fine. I would suggest you attach a document to troubleshoot.

amber2000
Creator
Creator
Author

If I re-create the situation in a test.qvw its working fine with Jannets expression or a combination of that expression.

Then I do the same in the original QVW (which is huge) and nothing happens.

When I leave out the field [Rec_Pallets] and use the expression  IF(Rec_End_Time>=0.6666607,Rec_End_Time) : only the records after 16:00 are visible.

The problem begins when I'm adding a count or sum of the Rec_Pallets field then I get all the End_Times again.

amber2000
Creator
Creator
Author

I think it's working now, I used this expression:

IF(Rec_End_Time>=0.6666607,Sum(Rec_Pallets))

Now the amount of pallets are showing correctly for all the End_Times after 16:00.

How can I change this expression if I want to show data for example between 16:00 and 18:00???

datagrrl
Creator III
Creator III

IF(Rec_End_Time>=0.6666607 and Rec_End_Time<=.75,Sum(Rec_Pallets))