Hi,

Since the stream graph query for my use case , didn't work as  i took the
data from solr source code test and also copied the schema and
solrconfig.xml from solr 7.6 source code.  Had to substitute few variables.

Posted below data

curl -X POST http://localhost:8983/solr/knr/update -H
'Content-type:text/csv' -d '
id, basket_s, product_s, prics_f
90,basket1,product1,20
91,basket1,product3,30
92,basket1,product5,1
93,basket2,product1,2
94,basket2,product6,5
95,basket2,product7,10
96,basket3,product4,20
97,basket3,product3,10
98,basket3,product1,10
99,basket4,product4,40
110,basket4,product3,10
111,basket4,product1,10'
After this I committed and made sure the data got published. to solr

curl --data-urlencode
'expr=gatherNodes(knr,walk="product1->product_s",gather="basket_s")'
http://localhost:8983/solr/knr/stream

{

  "result-set":{

    "docs":[{

        "EOF":true,

        "RESPONSE_TIME":4}]}}


and if I add *scatter="branches, leaves" , there is one doc.*



curl --data-urlencode
'expr=gatherNodes(knr,walk="product1->product_s",gather="basket_s",scatter="branches,
leaves")' http://localhost:8983/solr/knr/stream

{

  "result-set":{

    "docs":[{

        "node":"product1",

        "collection":"knr",

        "field":"node",

        "level":0}

      ,{

        "EOF":true,

        "RESPONSE_TIME":4}]}}




Below is the data I got from
https://github.com/apache/lucene-solr/blob/branch_7_6/solr/solrj/src/test/org/apache/solr/client/solrj/io/graph/GraphExpressionTest.java#L271



According to this test 4 docs are expected.


I am not sure what I am missing. Any pointers, please


Thanks you,

Rajeswari

Reply via email to