meta_query_find_compatible_table_alias filter-hookWP 4.1.0

Filters the table alias identified as compatible with the current clause.


add_filter( 'meta_query_find_compatible_table_alias', 'wp_kama_meta_query_find_compatible_table_alias_filter', 10, 4 );

 * Function for `meta_query_find_compatible_table_alias` filter-hook.
 * @param string|false  $alias        Table alias, or false if none was found.
 * @param array         $clause       First-order query clause.
 * @param array         $parent_query Parent of $clause.
 * @param WP_Meta_Query $query        WP_Meta_Query object.
 * @return string|false
function wp_kama_meta_query_find_compatible_table_alias_filter( $alias, $clause, $parent_query, $query ){

	// filter...
	return $alias;
Table alias, or false if none was found.
First-order query clause.
Parent of $clause.
WP_Meta_Query object.


Since 4.1.0 Introduced.

Where the hook is called

wp-includes/class-wp-meta-query.php 873
return apply_filters( 'meta_query_find_compatible_table_alias', $alias, $clause, $parent_query, $this );

Where the hook is used in WordPress

Usage not found.