title: Can I achieve a LIKE condition in a WHERE IN ARRAY query in doctrine?
body: <p>I am using Doctrine QueryBuilder to create a query to select a bunch of users by their email endings. I have an array of the e-mail endings, e.g. <code>['@someservice.com', '@anotherservice.com' ]</code>.</p>
  
  <p>I know I can select for string in an array via <code>WHERE IN</code>:</p>
  
  <pre><code>$qb= $this
      -&gt;createQueryBuilder('u')
      -&gt;orderBy('u.id', 'asc')
      -&gt;where('u.email IN (:emails)')
      -&gt;setParameter('emails', [
          '@someservice.com',
          '@anotherservice.com'
      ]);
  </code></pre>
  
  <p>Yet this query for exact occurrences of the string and hence the query will of course return an empty resultset.</p>
  
  <p>That's why I want to do a LIKE search on the array, yet doing something along the lines of:</p>
  
  <pre><code>$qb= $this
      -&gt;createQueryBuilder('u')
      -&gt;orderBy('u.id', 'asc')
      -&gt;where('u.email LIKE IN (:emails)')
      -&gt;setParameter('emails', [
          '%@someservice.com',
          '%@anotherservice.com'
      ]);
  </code></pre>
  
  <p>which unfortunately fails. Is there some syntactic sugar for doing a query like that or do I have to make query with a bunch of <code>orHaving</code> calls?</p>