-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[C#] Code Snippet for Atlas Search Autocomplete doesn't work #177
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
requesting changes because of a question
source/fundamentals/atlas-search.txt
Outdated
If the field you are searching has a search index, it must be included in your ``Autocomplete`` call: | ||
``Search.Autocomplete(g => g.Make, "Gib"), indexName: <make_search_index>)`` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Q: Is this issue unique to the Autocomplete()
Search method? Can you please check with the Pm to verify if all of the code examples used on this page need to include the search index name?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
According to the PM, yes, this is specific to Autocomplete and he did test all the methods except the Geo ones.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After reading the code example, I feel like the actual code example used in this section should be updated as well. The note could clarify that compared to the other examples, where the default
index is used in the absence of the index name, this example explicitly requires the index name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm with a final suggestion
source/fundamentals/atlas-search.txt
Outdated
@@ -106,6 +106,10 @@ collection using the string "Gib" in the ``make`` field. | |||
:language: csharp | |||
:dedent: | |||
|
|||
.. note:: | |||
|
|||
If the field you are searching has a search index, it must be included in your ``Autocomplete`` call. If a search index does not exist, the default index is used. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the field you are searching has a search index, it must be included in your ``Autocomplete`` call. If a search index does not exist, the default index is used. | |
If the field you are searching on is indexed by a search index, you must pass the index name to the | |
``Autocomplete`` call. If a search index does not exist, the search uses the default index. |
…#177) * add note about search index
Pull Request Info
PR Reviewing Guidelines
JIRA - https://jira.mongodb.org/browse/DOCSP-37267
Staging - https://docs-mongodbcom-staging.corp.mongodb.com/csharp/docsworker-xlarge/DOCSP-37267/fundamentals/atlas-search/#std-label-csharp-atlas-search
Self-Review Checklist