title: Core Data NSPredicate fetch on entity relationship using in clause
body: <p>I would like to be able to search the relationship of an entity using an IN clause.
  I have the following setup:
  <img src="https://i.stack.imgur.com/7qCSH.png" alt="enter image description here"></p>
  
  <p>I would like to send over an array of nicknames and find all Persons associated with those nicknames.</p>
  
  <pre><code>//array of names to find
  let nameArray: [String] = ["Tom", "Tommy", "Thomas"] 
  
  // find all Persons who have a nickname associated with that person           
  let predicate = NSPredicate(format: "ANY Person.nickName in %@",nameArray)
  var fetch = NSFetchRequest(entityName: "Person")
  fetch.predicate = predicate
  var fetchError : NSError? = nil
  
  // executes fetch
  let results = context?.executeFetchRequest(fetch, error: &amp;fetchError)
  </code></pre>
  
  <p>But when I run the code, I get the following error:</p>
  
  <p><strong>'NSInvalidArgumentException', reason: 'unimplemented SQL generation for predicate : (ANY Person.nickName IN {"Tom", "Tommy", "Thomas"})'</strong></p>
  
  <p>What am I doing wrong here? If I remove the predicate search, it returns all the results ok, but as soon as I add this line in, everything breaks.</p>