title: Better way of querying NOTIN in Spring Data JPA
body: <p>Using Spring Data JPA, I am using below jpa query (it works just fine) to query all the users except who is logged in (to get peers list).</p>
  <pre><code>appUserRepository.findByUsernameNotIn(new ArrayList&lt;String&gt;(Arrays.asList(getPrincipal()))).toString()
  </code></pre>
  <p>Since NotIn accepts collection only, and I had to filter-out just one name, I am using this 'clumsy' looking statement.</p>
  <p><strong>Question:</strong> Is there a better (short) way of achieving this? Meaning, getting all usernames from user table, except the logged-in user? Any clue/help will be highly appreciated.</p>