Are there any ES committers on the mailing list who wouldn't mind commenting on this issue?
If I have two different types "user" and "session", and both of them have and "id" field, shouldn't ElasticSearch understand that those are two different fields, and that their fully-qualified names are actually "user.id" and "session.id"? Using only fully-qualified names in the lucene internals seems like a straightforward way to fix the problem. Incidentally, it looks like there's a bug-report (submitted two YEARS ago!) here: https://github.com/elasticsearch/elasticsearch/issues/1737 If this is the desirable behavior, then why hasn't this bug been closed as "won't fix"? Or if it's legitimately a bug, why wasn't it fixed before releasing 1.0? It seems like a pretty fundamental flaw in the system that the functionality of one type can be broken by the definition of another essentially unrelated type. I can understand why the behavior is what it is, historically, but it seems self-evidently like a bug. In what kind of system would this be the desirable behavior? Thanks! benji On Thursday, February 13, 2014 10:48:56 AM UTC-5, Benji Smith wrote: > > Yes, you guys are right. There are multiple different types in this index, > and some of them have LONG ids, while others have INTEGER or STRING ids. > I'll have to redesign a few parts of the mappings to fix that problem. > > I suppose the same restriction applies across nested types as well, right? > I'm heavily using nested types, and many of them have their own inner ID > fields. > > Thanks for your help! > > benji > > On Thursday, February 13, 2014 7:45:37 AM UTC-5, Binh Ly wrote: >> >> Like Alex mentioned, I would check all the mappings to ensure the types >> of the id field are all the same (doesn't matter what the value is in it - >> what matters is the type defined in the mapping). Your error message means: >> in one type the id field is long (in the mapping), and in the other type >> the id field is int (in the mapping). And you are querying across those 2 >> types which gives this error. >> > -- You received this message because you are subscribed to the Google Groups "elasticsearch" group. To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/24c29e85-6a94-426d-9746-71960b23fd4c%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.