title: How to form dynamic key value array inside meta_query wordpress
body: <p>This is my meta query </p>
  
  <pre><code>$args = array(
      'post_type'  =&gt; 'auto',
      'meta_query' =&gt; array(          
          array(
              'key'     =&gt; 'a',
              'value'   =&gt; 'test', 
          ),
          array(
              'key' =&gt; 'b',
              'value'   =&gt; 'test', 
          ),
          array(
              'key' =&gt; 'c',
              'value'   =&gt; '', 
          ),
          array(
              'key' =&gt; 'd',
              'value'   =&gt; '', 
          ),
          array(
              'key' =&gt; 'e',
              'value'   =&gt; '', 
          ),
          array(
              'key' =&gt; 'f',
              'value'   =&gt; '', 
          ),
          array(
              'key' =&gt; 'g',
              'value'   =&gt; '', 
          ),
  
      ),
  );
  </code></pre>
  
  <p>I need to form the array dynamically like if array values of certain key is null then it should not be appended to the meta query.</p>
  
  <p>Example in the above array key 'c' value is null so it should not be there in the meta query like wise i have more list of key values pairs , any help is appreciated , thanks in advance.</p>