Opened 2 years ago

Closed 2 years ago

Last modified 2 years ago

#16573 closed defect (bug) (duplicate)

meta_query doesnt support "empty" values

Reported by: dd32 Owned by:
Priority: normal Milestone:
Component: Query Version: 3.1
Severity: normal Keywords: needs-patch
Cc:

Description

Basically, a meta_value of '0' is ignored in meta queries, It bases it on empty(), so a meta value being "empty" is ignored.

This mainly comes into play for numeric comparisons, ie. field >= 0 (do not want -50 etc)

Code: Line 423 change from empty() to strlen()?

Core includes a hack to work around this already

Change History (3)

comment:1   dd322 years ago

  • Milestone Future Release deleted
  • Resolution set to duplicate
  • Status changed from new to closed

of course it was reported 4 months ago.. #15292

Not quite the same thing, but I'll run with it.

I meant to post this comment on #16735.

Note: See TracTickets for help on using tickets.