The example is using two collections: people and pets. So these collections would need to be present for the join expression to work.
Joel Bernstein http://joelsolr.blogspot.com/ On Mon, May 9, 2016 at 10:43 PM, Ryan Cutter <ryancut...@gmail.com> wrote: > Thanks Joel, I added the personId and ownerId fields before ingested a > little data. I made them to be stored=true/multiValue=false/longs (and > strings, later). Is additional schema required? > > On Mon, May 9, 2016 at 6:45 PM, Joel Bernstein <joels...@gmail.com> wrote: > > > Hi, > > > > The example in the cwiki would require setting up the people and pets > > collections. Unless I'm mistaken this won't work with the out of the box > > schemas. So you'll need to setup some test schemas to get started. > Although > > having out of the box streaming schemas is a great idea. > > > > Joel Bernstein > > http://joelsolr.blogspot.com/ > > > > On Mon, May 9, 2016 at 9:22 PM, Ryan Cutter <ryancut...@gmail.com> > wrote: > > > > > Hello, I'm checking out the cool stream join operations in Solr 6.0 but > > > can't seem to the example listed on the wiki to work: > > > > > > > > > > > > https://cwiki.apache.org/confluence/display/solr/Streaming+Expressions#StreamingExpressions-innerJoin > > > > > > innerJoin( > > > search(people, q=*:*, fl="personId,name", sort="personId asc"), > > > search(pets, q=type:cat, fl="ownerId,petName", sort="ownerId asc"), > > > on="personId=ownerId" > > > ) > > > > > > ERROR - 2016-05-09 21:42:43.497; [c:pets s:shard1 r:core_node1 > > > x:pets_shard1_replica1] org.apache.solr.common.SolrException; > > > java.io.IOException: java.lang.NullPointerException > > > > > > at > > > > > > > > > org.apache.solr.client.solrj.io.stream.CloudSolrStream.constructStreams(CloudSolrStream.java:339) > > > > > > 1. Joel Bernstein pointed me at SOLR-9058. Is this the likely bug? > > > 2. What kind of field should personId and ownerId be? long, string, > > > something else? > > > 3. Does someone have an example schema or dataset that show off these > > > joins? If not, it's something I could work on for future souls. > > > > > > Thanks! Ryan > > > > > >