title: how to correctly use query on get , when I need 2 different queries for the same field ReactJs
body: <p>I would like to explain my problem of the day.</p>
  <p>i call data here</p>
  <pre><code> const { data: data } = useQuery(
      [filterLocations],
      async () =&gt;
          await users.getAll({
              query: {
                  locations: filterLocations,
              },
          }),
  );
  </code></pre>
  <p>this data</p>
  <pre><code> [
    { id: &quot;a&quot;, location: &quot;&quot;} ,
    { id: &quot;b&quot;, location: &quot;eng&quot; } , 
    { id: &quot;c&quot;, location: &quot;ES&quot;} , 
    { id: &quot;d&quot;, location: &quot;FR&quot;} ,
   ]
  </code></pre>
  <p>this filterLocations</p>
  <pre><code>let filterLocations;
   if (countryFilter.length === 0) {
       filterLocations = undefined;
   } else {
      filterLocations = queryFilter?.query?.location;
   }
  </code></pre>
  <p>then I have a select which allows to change location</p>
  <pre><code>    &lt;DropdownSelect
                          options={countries}
                          getValue={(values) =&gt; {
                              if (!values?.value.length) {
                                  setCountryFilter([]);
                                  setQueryFilter((prevState) =&gt; ({
                                      ...prevState,
                                      query: {
                                          ...prevState.query,
                                          location: {
                                              $in: countries?.map(
                                                  (e) =&gt; e.value
                                              ),
                                          },
                                      },
                                      page: 1,
                                  }));
                              } else {
                                  setCountryFilter(values.value);
                                  setQueryFilter((prevState) =&gt; ({
                                      ...prevState,
                                      page: 1,
                                      query: {
                                          ...prevState.query,
                                          location: {
                                              $in: values.value.map(
                                                  (e) =&gt; e.value
                                              ),
                                          },
                                      },
                                  }));
                              }
                          }}
                          value={countryFilter}
                      /&gt;
  </code></pre>
  <p>this works correctly.</p>
  <p>when i select country the result of data becomes ( i select ES )</p>
  <pre><code>[
   { id: &quot;c&quot;, location: &quot;ES&quot;} , 
  ]
  </code></pre>
  <p>so this is very good</p>
  <p>but I would rather receive</p>
  <pre><code>[
   { id: &quot;a&quot;, location: &quot;&quot;} ,
   { id: &quot;c&quot;, location: &quot;ES&quot;} , 
  ]
  </code></pre>
  <p>basically if the location is empty, I need this data to also be returned</p>
  <p>iam open to any proposal thank you very much.</p>
  <p>Neff</p>