Query using chfieldfrom parameter seems to ignore the time component




Query/Bug List
7 years ago
4 years ago


(Reporter: Andy, Unassigned)






7 years ago
User-Agent:       Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv: Gecko/2010031706 Red Hat/3.0.19-1.el5_5 Firefox/3.0.19
Build Identifier: Bugzilla 4.1.1, Firefox 3.0.19

Please note that the above URL is for our internal instance (and just included for reference purposes).

When using a buglist.cgi query with a chfieldfrom parameter (including a date and time) on our Bugzilla 4.1.1 instance, the query looks like it returns bugs changed on or after the date specified, regardless of the time defined in the query.  In our other Bugzilla 3.x instance this functionality worked ok.  Note that this problem occurs in our Bugzilla 4.1.1 instance, but I cannot get it to repeat in Bugzilla's own instance (e.g. at https://bugzilla.mozilla.org/buglist.cgi?chfieldfrom=2011-04-12T12:00:00&product=Bugzilla), and I'm not sure what version this is running (perhaps this is running 4.0)

I've checked the date / time configuration on our Bugzilla and database servers, and these look ok.

Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv: Gecko/2010031706 Red Hat/3.0.19-1.el5_5 Firefox/3.0.19

Reproducible: Always

Steps to Reproduce:
1. On Bugzilla 4.1.1, enter the URL similar to the format above, but specify both a time and date.

Actual Results:  
See that bugs that were changed on the date specified, but before the time specified still show up.

Comment 1

7 years ago
Hmm, okay. Does it work if you use a space instead of the T?

Comment 2

7 years ago
Note by the way that the trunk's Search.pm is undergoing heavy refactoring, so we do expect these sorts of strange bugs to crop up from time to time before we're stable.

Comment 3

7 years ago
Yes, looks like it does work correctly if there's a space inside of the T

Comment 4

7 years ago
Doh, sorry - "instead" of the T

Comment 5

7 years ago
All right. That could possibly just be an issue with your database not accepting the T format. Do you think you'd be capable of verifying whether or not that's the case?

Comment 6

7 years ago
Thanks Max, I hadn't thought about checking that.  I did go in (into both our Bz3.x and our Bz 4.x databases), and tried queries (both with and without the "T") along the lines of the below, and they all seemed to work as intended (they all took into account the "time" element correctly).  Both 3.x and V4 database setups looked the same from a brief check.

SELECT bug_id, delta_ts FROM bugs WHERE product_id='101' AND delta_ts>'2011-04-12T18:00:00' 


SELECT bug_id, delta_ts FROM bugs WHERE product_id='101' AND delta_ts>'2011-04-12 18:00:00'

Comment 7

7 years ago
Okay, thanks! So this is a bug in Bugzilla then. It may not get fixed very quickly; it could be an issue with the date-parsing libraries we're using, which should slowly be replaced, but haven't been yet.
Severity: normal → minor
Ever confirmed: true
OS: Linux → All
Hardware: x86 → All

Comment 8

7 years ago
Changed importance to "normal" (from "minor") since a 3rd party whose tools we use depends on this feature :-)
Severity: minor → normal

Comment 9

6 years ago
I looked at this again, and it appears to be a Bugzilla bug that has crept in since 4.0.  From looking at the Mozilla landfill Bugzilla instances, it works ok in 4.0, but is a problem in the 4.2 RC.

e.g. https://landfill.bugzilla.org/bugzilla-4.2-branch/buglist.cgi?chfieldfrom=2012-01-04T23:59:00&product=FoodReplicator

will return bugs changed earlier in the day on 2012/01/04, but replacing the "T" with a blank space will show the correct results.  However a similar query on https://landfill.bugzilla.org/bugzilla-4.0-branch works ok
You need to log in before you can comment on or make changes to this bug.