I looked at the managed-schema and it does appear that fields like "name"
were not indexed (if I'm reading this correctly):

<field name="name" type="strings"/>

Not sure if this is because some step was missed, the post command was done
incorrectly, or what. Tutorial says nothing about schemas or indexes. For
reference, here's the entire tutorial run, copied and pasted from my
terminal window with just a few ellipses to collapse the 4000+ document
loads and query results.

marplon:solr-6.2.0 jpritchett$ ./bin/solr start -e cloud -noprompt

Welcome to the SolrCloud example!

Starting up 2 Solr nodes for your example SolrCloud cluster.

Creating Solr home directory
/Users/jpritchett/solr-6.2.0/example/cloud/node1/solr
Cloning /Users/jpritchett/solr-6.2.0/example/cloud/node1 into
   /Users/jpritchett/solr-6.2.0/example/cloud/node2

Starting up Solr on port 8983 using command:
bin/solr start -cloud -p 8983 -s "example/cloud/node1/solr"

Waiting up to 30 seconds to see Solr running on port 8983 [-]
Started Solr server on port 8983 (pid=8216). Happy searching!


Starting up Solr on port 7574 using command:
bin/solr start -cloud -p 7574 -s "example/cloud/node2/solr" -z
localhost:9983

Waiting up to 30 seconds to see Solr running on port 7574 [/]
Started Solr server on port 7574 (pid=8408). Happy searching!


Connecting to ZooKeeper at localhost:9983 ...
Uploading
/Users/jpritchett/solr-6.2.0/server/solr/configsets/data_driven_schema_configs/conf
for config gettingstarted to ZooKeeper at localhost:9983

Creating new collection 'gettingstarted' using command:
http://localhost:8983/solr/admin/collections?action=CREATE&name=gettingstarted&numShards=2&replicationFactor=2&maxShardsPerNode=2&collection.configName=gettingstarted

{
  "responseHeader":{
    "status":0,
    "QTime":16272},
  "success":{
    "172.16.3.78:8983_solr":{
      "responseHeader":{
        "status":0,
        "QTime":7526},
      "core":"gettingstarted_shard1_replica2"},
    "172.16.3.78:7574_solr":{
      "responseHeader":{
        "status":0,
        "QTime":7838},
      "core":"gettingstarted_shard2_replica1"}}}

Enabling auto soft-commits with maxTime 3 secs using the Config API

POSTing request to Config API:
http://localhost:8983/solr/gettingstarted/config
{"set-property":{"updateHandler.autoSoftCommit.maxTime":"3000"}}
Successfully set-property updateHandler.autoSoftCommit.maxTime to 3000


SolrCloud example running, please visit: http://localhost:8983/solr

marplon:solr-6.2.0 jpritchett$ bin/post -c gettingstarted docs/
java -classpath /Users/jpritchett/solr-6.2.0/dist/solr-core-6.2.0.jar
-Dauto=yes -Dc=gettingstarted -Ddata=files -Drecursive=yes
org.apache.solr.util.SimplePostTool docs/
SimplePostTool version 5.0.0
Posting files to [base] url
http://localhost:8983/solr/gettingstarted/update...
Entering auto mode. File endings considered are
xml,json,jsonl,csv,pdf,doc,docx,ppt,pptx,xls,xlsx,odt,odp,ods,ott,otp,ots,rtf,htm,html,txt,log
Entering recursive mode, max depth=999, delay=0s
Indexing directory docs (3 files, depth=0)
POSTing file index.html (text/html) to [base]/extract
POSTing file quickstart.html (text/html) to [base]/extract

[etc.]

POSTing file SolrVelocityResourceLoader.html (text/html) to [base]/extract
POSTing file VelocityResponseWriter.html (text/html) to [base]/extract
4329 files indexed.
COMMITting Solr index changes to
http://localhost:8983/solr/gettingstarted/update...
Time spent: 0:06:03.224
marplon:solr-6.2.0 jpritchett$ bin/post -c gettingstarted
example/exampledocs/*.xml
java -classpath /Users/jpritchett/solr-6.2.0/dist/solr-core-6.2.0.jar
-Dauto=yes -Dc=gettingstarted -Ddata=files
org.apache.solr.util.SimplePostTool example/exampledocs/gb18030-example.xml
example/exampledocs/hd.xml example/exampledocs/ipod_other.xml
example/exampledocs/ipod_video.xml example/exampledocs/manufacturers.xml
example/exampledocs/mem.xml example/exampledocs/money.xml
example/exampledocs/monitor.xml example/exampledocs/monitor2.xml
example/exampledocs/mp500.xml example/exampledocs/sd500.xml
example/exampledocs/solr.xml example/exampledocs/utf8-example.xml
example/exampledocs/vidcard.xml
SimplePostTool version 5.0.0
Posting files to [base] url
http://localhost:8983/solr/gettingstarted/update...
Entering auto mode. File endings considered are
xml,json,jsonl,csv,pdf,doc,docx,ppt,pptx,xls,xlsx,odt,odp,ods,ott,otp,ots,rtf,htm,html,txt,log
POSTing file gb18030-example.xml (application/xml) to [base]
POSTing file hd.xml (application/xml) to [base]

[etc.]

14 files indexed.
COMMITting Solr index changes to
http://localhost:8983/solr/gettingstarted/update...
Time spent: 0:00:07.578
marplon:solr-6.2.0 jpritchett$ bin/post -c gettingstarted
example/exampledocs/books.json
java -classpath /Users/jpritchett/solr-6.2.0/dist/solr-core-6.2.0.jar
-Dauto=yes -Dc=gettingstarted -Ddata=files
org.apache.solr.util.SimplePostTool example/exampledocs/books.json
SimplePostTool version 5.0.0
Posting files to [base] url
http://localhost:8983/solr/gettingstarted/update...
Entering auto mode. File endings considered are
xml,json,jsonl,csv,pdf,doc,docx,ppt,pptx,xls,xlsx,odt,odp,ods,ott,otp,ots,rtf,htm,html,txt,log
POSTing file books.json (application/json) to [base]/json/docs
1 files indexed.
COMMITting Solr index changes to
http://localhost:8983/solr/gettingstarted/update...
Time spent: 0:00:01.782
marplon:solr-6.2.0 jpritchett$ bin/post -c gettingstarted
example/exampledocs/books.csv
java -classpath /Users/jpritchett/solr-6.2.0/dist/solr-core-6.2.0.jar
-Dauto=yes -Dc=gettingstarted -Ddata=files
org.apache.solr.util.SimplePostTool example/exampledocs/books.csv
SimplePostTool version 5.0.0
Posting files to [base] url
http://localhost:8983/solr/gettingstarted/update...
Entering auto mode. File endings considered are
xml,json,jsonl,csv,pdf,doc,docx,ppt,pptx,xls,xlsx,odt,odp,ods,ott,otp,ots,rtf,htm,html,txt,log
POSTing file books.csv (text/csv) to [base]
1 files indexed.
COMMITting Solr index changes to
http://localhost:8983/solr/gettingstarted/update...
Time spent: 0:00:00.204
marplon:solr-6.2.0 jpritchett$ curl "
http://localhost:8983/solr/gettingstarted/select?wt=json&indent=true&q=foundation
"
{
  "responseHeader":{
    "zkConnected":true,
    "status":0,
    "QTime":264,
    "params":{
      "q":"foundation",
      "indent":"true",
      "wt":"json"}},
  "response":{"numFound":4156,"start":0,"maxScore":0.098080166,"docs":[
      {
        "id":"0553293354",
        "cat":["book"],
        "name":["Foundation"],
        "price":[7.99],
        "inStock":[false],
        "author":["Isaac Asimov"],
        "series_t":["Foundation Novels"],
        "sequence_i":1,
        "genre_s":"scifi",
        "_version_":1545646368061652992},

        [etc.]]
  }}
marplon:solr-6.2.0 jpritchett$ curl "
http://localhost:8983/solr/gettingstarted/select?wt=json&indent=true&q=name:foundation
"
{
  "responseHeader":{
    "zkConnected":true,
    "status":0,
    "QTime":47,
    "params":{
      "q":"name:foundation",
      "indent":"true",
      "wt":"json"}},
  "response":{"numFound":0,"start":0,"maxScore":0.0,"docs":[]
  }}
marplon:solr-6.2.0 jpritchett$


On Fri, Sep 16, 2016 at 11:40 AM, Erick Erickson <erickerick...@gmail.com>
wrote:

> My bet:
> the fields (look in managed_schema or, possibly schema.xml)
> has stored="true" and indexed="false" set for the fields
> in question.
>
> Pretty much everyone takes a few passes before this really
> makes sense. "stored" means you see the results returned,
> "indexed" must be true before you can search on something.
>
> Second possibility: You've somehow indexed fields as
> "string" type rather than one of the text based fieldTypes.
> "string" types are not tokenized, thus a field with
> "My dog has fleas" will fail to find "My". It'll even not match
> "my dog has fleas" (note capital "M").
>
> The admin UI>>select core>>analysis page will show you
> lots of this kind of detail, although I admit it takes a bit to
> understand all the info (do un-check the "verbose" button
> for the nonce).
>
> Now, all that aside, please show us the field definition for
> one of the fields in question and, as John mentions, the exact
> query (I'd also ass &debugQuery=true to the results).
>
> Saying you followed the exact instructions somewhere isn't
> really helpful. It's likely that there's something innocent-seeming
> that was done differently. Giving the information asked for
> will help us diagnose what's happening and, perhaps,
> improve the docs if we can understand the mis-match.
>
> Best,
> Erick
>
> On Fri, Sep 16, 2016 at 8:28 AM, Pritchett, James
> <jpritch...@learningally.org> wrote:
> > I am following the exact instructions in the tutorial: copy and pasting
> all
> > commands & queries from the tutorial:
> > https://lucene.apache.org/solr/quickstart.html. Where it breaks down is
> > this one:
> >
> > http://localhost:8983/solr/gettingstarted/select?wt=json&;
> indent=true&q=name:foundation
> >
> > This returns no results. Tried in the web admin view as well, also tried
> > various field:value combinations to no avail. Clearly something didn't
> get
> > configured correctly, but I saw no error messages when running all the
> data
> > loads, etc. given in the tutorial.
> >
> > Sorry to be so clueless, but I don't really have anything to go on for
> > troubleshooting besides asking dumb questions.
> >
> > James
> >
> > On Fri, Sep 16, 2016 at 11:24 AM, John Bickerstaff <
> j...@johnbickerstaff.com
> >> wrote:
> >
> >> Please share the exact query syntax?
> >>
> >> Are you using a collection you built or one of the examples?
> >>
> >> On Fri, Sep 16, 2016 at 9:06 AM, Pritchett, James <
> >> jpritch...@learningally.org> wrote:
> >>
> >> > I apologize if this is a really stupid question. I followed all
> >> > instructions on installing Tutorial, got data loaded, everything works
> >> > great until I try to query with a field name -- e.g.,
> name:foundation. I
> >> > get zero results from this or any other query which specifies a field
> >> name.
> >> > Simple queries return results, and the field names are listed in those
> >> > results correctly. But if I query using names that I know are there
> and
> >> > values that I know are there, I get nothing.
> >> >
> >> > I figure this must be something basic that is not right about the way
> >> > things have gotten set up, but I am completely blocked at this point.
> I
> >> > tried blowing it all away and restarting from scratch with no luck.
> Where
> >> > should I be looking for problems here? I am running this on a MacBook,
> >> OS X
> >> > 10.9, latest JDK (1.8).
> >> >
> >> > James
> >> >
> >> > --
> >> >
> >> >
> >> > *James Pritchett*
> >> >
> >> > Leader, Process Redesign and Analysis
> >> >
> >> > ______________________________
> >> >
> >> >
> >> > *Learning Ally™*Together It’s Possible
> >> > 20 Roszel Road | Princeton, NJ 08540 | Office: 609.243.7608
> >> >
> >> > jpritch...@learningally.org
> >> >
> >> > www.LearningAlly.org <http://www.learningally.org/>
> >> >
> >> > Join us in building a community that helps blind, visually impaired &
> >> > dyslexic students thrive.
> >> >
> >> > Connect with our community: *Facebook*
> >> > <https://www.facebook.com/LearningAlly.org> | *Twitter*
> >> > <https://twitter.com/Learning_Ally> | *LinkedIn*
> >> > <https://www.linkedin.com/groups?home=&gid=2644842&trk=anet_ug_hm> |
> >> > *Explore1in5* <http://www.explore1in5.org/> | *Instagram*
> >> > <https://instagram.com/Learning_Ally/> | *Sign up for our community
> >> > newsletter* <https://go.learningally.org/about-learning-ally/stay-in-
> >> > touch/>
> >> >
> >> > Support us: *Donate*
> >> > <https://go.learningally.org/about-learning-ally/donate/> |
> *Volunteer*
> >> > <https://go.learningally.org/about-learning-ally/
> >> > volunteers/how-you-can-help/>
> >> >
> >>
> >
> >
> >
> > --
> >
> >
> > *James Pritchett*
> >
> > Leader, Process Redesign and Analysis
> >
> > ______________________________
> >
> >
> > *Learning Ally™*Together It’s Possible
> > 20 Roszel Road | Princeton, NJ 08540 | Office: 609.243.7608
> >
> > jpritch...@learningally.org
> >
> > www.LearningAlly.org <http://www.learningally.org/>
> >
> > Join us in building a community that helps blind, visually impaired &
> > dyslexic students thrive.
> >
> > Connect with our community: *Facebook*
> > <https://www.facebook.com/LearningAlly.org> | *Twitter*
> > <https://twitter.com/Learning_Ally> | *LinkedIn*
> > <https://www.linkedin.com/groups?home=&gid=2644842&trk=anet_ug_hm> |
> > *Explore1in5* <http://www.explore1in5.org/> | *Instagram*
> > <https://instagram.com/Learning_Ally/> | *Sign up for our community
> > newsletter* <https://go.learningally.org/about-learning-ally/stay-in-
> touch/>
> >
> > Support us: *Donate*
> > <https://go.learningally.org/about-learning-ally/donate/> | *Volunteer*
> > <https://go.learningally.org/about-learning-ally/
> volunteers/how-you-can-help/>
>



-- 


*James Pritchett*

Leader, Process Redesign and Analysis

______________________________


*Learning Ally™*Together It’s Possible
20 Roszel Road | Princeton, NJ 08540 | Office: 609.243.7608

jpritch...@learningally.org

www.LearningAlly.org <http://www.learningally.org/>

Join us in building a community that helps blind, visually impaired &
dyslexic students thrive.

Connect with our community: *Facebook*
<https://www.facebook.com/LearningAlly.org> | *Twitter*
<https://twitter.com/Learning_Ally> | *LinkedIn*
<https://www.linkedin.com/groups?home=&gid=2644842&trk=anet_ug_hm> |
*Explore1in5* <http://www.explore1in5.org/> | *Instagram*
<https://instagram.com/Learning_Ally/> | *Sign up for our community
newsletter* <https://go.learningally.org/about-learning-ally/stay-in-touch/>

Support us: *Donate*
<https://go.learningally.org/about-learning-ally/donate/> | *Volunteer*
<https://go.learningally.org/about-learning-ally/volunteers/how-you-can-help/>

Reply via email to