WordPress.org

Ready to get started?Download WordPress

Forums

Meta Query w/ AND and OR (2 posts)

  1. whatadewitt
    Member
    Posted 2 years ago #

    http://pastebin.com/M528Ds9L

    What I'm trying to do here is query by meta where "meta_key1" = X OR "meta_key2" = X but it's mixed in there with a couple of other meta keys that would be ANDs

    in the most basic explanation I'm trying to say

    this AND this AND (this OR this)

    but I can't seem to figure out how to do it.

    Can anyone help me out? Thanks!

    --d

  2. vtxyzzy
    Member
    Posted 2 years ago #

    I am not sure you can handle this with meta_query, but it can probably be done using filters on the query. Can you be more specific about the key names and values that you want to select?

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags