This one’s going to be a bit of a challenge to describe. I have a very unusual case I need to write a query for in WordPress.
I have a post type, called artists
, and another one, called performances
. Artists have a meta value with the key artist_id
.
Performances have the same meta key, referencing the artist. I realize this alternate subsystem of IDs is ridiculous, but it’s the way things are for a bunch of other reasons, you’ll have to trust me that they’re sensible.
Performances have another meta key of show_set_time
that contains a UNIX timestamp.
I need to write a query that can get me all artists that have a performance after a certain date.
Let me know if that’s unclear. I completely recognize, again, that the ID keys are ridiculous, but there are other factors involved.
This is obviously untested, but I think it should work: