Body: <p>I can do <code>craft.entries.section('mySection').relatedTo(item.id)</code> and it will return the result, so i assumed i could do <code>craft.entries.section(['mySection','mySection2','mySection3']).relatedTo(item.id)</code> but, the latter seems to return no results.</p>
  
  <p>Any input would be greatly appreciated!</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-04-19T18:48:00.053Z
Comments.Text: Are you sure the 3 sections have elements related to your `item.id`?  If you take off the `relatedTo` part, do you get all entries across all 3 sections?
Comments.UserDisplayName: Brad Bell
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-04-19T19:52:16.077Z
Comments.Text: Ah, now, does it mean it will return entries where they have a relationship in `mySection AND mySection2 AND mySection3` rather than the desired `mySection OR mySection2 OR mySection3` ?
Comments.UserDisplayName: John
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-04-19T20:03:00.343Z
Comments.Text: Without looking at the code... about 90% sure it will end up being an OR.
Comments.UserDisplayName: Brad Bell
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-04-19T21:22:10.703Z
Comments.Text: Well, the 3 sections do have elements related to item.id and if i take off the relatedTo part, i do indeed get entries across all 3 sections! No idea why it's not returning entries in my original code!
Comments.UserDisplayName: John
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-04-19T22:24:00.457Z
Comments.Text: maybe change relatedTo(item.id) to relatedTo(item)
Comments.UserDisplayName: Brad
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-04-19T22:32:12.650Z
Comments.Text: Yep, was one step ahead of you, i had already tried that! No dice however.
Comments.UserDisplayName: John
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-05-18T20:34:09.957Z
Comments.Text: Sorry - more questions. Is `item` defined? Is it an `entry` object and does the query return anything with only one section?
Comments.UserDisplayName: Clive Portman
Tags: <entries><relatedto>
Title: relatedTo doesn't seem to work when using multiple sections in a craft.entries call
ThreadText: # relatedTo doesn't seem to work when using multiple sections in a craft.entries call
  
  (Asked by: username_0 on 2017-04-19)
  
  I can do `craft.entries.section('mySection').relatedTo(item.id)` and it will return the result, so i assumed i could do `craft.entries.section(['mySection','mySection2','mySection3']).relatedTo(item.id)` but, the latter seems to return no results.
  
  Any input would be greatly appreciated!
  
  **Tags:** entries, relatedto
  
  > **Comments:**
  > **username_1**: Are you sure the 3 sections have elements related to your `item.id`?  If you take off the `relatedTo` part, do you get all entries across all 3 sections?  
  > **username_0**: Ah, now, does it mean it will return entries where they have a relationship in `mySection AND mySection2 AND mySection3` rather than the desired `mySection OR mySection2 OR mySection3` ?  
  > **username_1**: Without looking at the code... about 90% sure it will end up being an OR.  
  > **username_0**: Well, the 3 sections do have elements related to item.id and if i take off the relatedTo part, i do indeed get entries across all 3 sections! No idea why it's not returning entries in my original code!  
  > **username_2**: maybe change relatedTo(item.id) to relatedTo(item)  
  > **username_0**: Yep, was one step ahead of you, i had already tried that! No dice however.  
  > **username_3**: Sorry - more questions. Is `item` defined? Is it an `entry` object and does the query return anything with only one section?  
  
  ---
  
  ## 0 answers
  
  