The query works if you change "publish" to "draft" or remove the source clause. These are args passed to the WP_Query constructor. I immediately count the results to verify that WP_Query is in fact returning no results. I checked the data in the database and made sure the data is congruent.
Array
(
[post_type] => post
[post_status] => Array
(
[0] => publish
)
[meta_query] => Array
(
[view_count_clause] => Array
(
[key] => _viewcount
[type] => NUMERIC
)
[actual_date_clause] => Array
(
[key] => _actualdate
)
[start_date_clause] => Array
(
[key] => _actualdate
[value] => 2021-03-23 00-00-00
[compare] => >
)
[end_date_clause] => Array
(
[key] => _actualdate
[value] => 2021-03-24 00-00-00
[compare] => <
)
[color_clause] => Array
(
[key] => _color
[type] => NUMERIC
[compare] => IN
[value] => Array
(
[0] => 4
)
)
[source_clause] => Array
(
[key] => _sourcename
[value] => AHA
[compare] => =
)
)
[orderby] => Array
(
[actual_date_clause] => DESC
)
)
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…