Skip to content

Commit a44c7c0

Browse files
[DOC-11985] Unite the Search sections in Server (couchbaselabs#177)
* [DOC-11985] Made some changes to existing documentation to support the removal of fts/ files on docs-server - mostly picking up bits that fell through the cracks Adding page aliases to all required pages Adding extra fts/ content to nav.adoc * Fix Analyzer alias --------- Co-authored-by: Simon Dew <39966290+simon-dew@users.noreply.github.com>
1 parent ea50289 commit a44c7c0

28 files changed

+210
-86
lines changed

modules/n1ql/pages/n1ql-language-reference/searchfun.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
= Search Functions
22
:description: Search functions enable you to use Full Text Search (FTS) queries directly within a {sqlpp} query.
33
:page-topic-type: reference
4+
:page-aliases: fts:fts-searching-from-N1QL.adoc
45
:example-caption!:
56
:imagesdir: ../../assets/images
67
:underscore: _

modules/search/examples/geospatial-search-index.jsonc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,8 @@
4141
"include_in_all": true,
4242
"index": true,
4343
"name": "$FIELD_NAME",
44-
"type": "geopoint"
44+
//Replace with "geoshape" if your field contains GeoJSON data, instead.
45+
"type": "geopoint"
4546
}
4647
]
4748
}
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
curl -s -XPUT -H "Content-Type: application/json" \
2+
-u ${CB_USERNAME}:${CB_PASSWORD} http://${CB_HOSTNAME}:8094/api/bucket/${BUCKET-NAME}/scope/${SCOPE-NAME}/index/${INDEX-NAME}/query
3+
-d '{
4+
"query": {
5+
"field": "geojson",
6+
"geometry": {
7+
"shape": {
8+
"type": "Polygon",
9+
"coordinates": [
10+
[
11+
[
12+
0.47482593026924746,
13+
51.31232878073189
14+
],
15+
[
16+
0.6143265647863245,
17+
51.31232878073189
18+
],
19+
[
20+
0.6143265647863245,
21+
51.384000374770466
22+
],
23+
[
24+
0.47482593026924746,
25+
51.384000374770466
26+
],
27+
[
28+
0.47482593026924746,
29+
51.31232878073189
30+
]
31+
]
32+
]
33+
},
34+
"relation": "within"
35+
}
36+
}
37+
}

modules/search/examples/geospatial-search-query.jsonc

Lines changed: 0 additions & 23 deletions
This file was deleted.
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
curl -s -XPUT -H "Content-Type: application/json" \
2+
-u ${CB_USERNAME}:${CB_PASSWORD} http://${CB_HOSTNAME}:8094/api/bucket/${BUCKET-NAME}/scope/${SCOPE-NAME}/index/${INDEX-NAME}/query
3+
-d '{
4+
"from": 0,
5+
"size": 10,
6+
"query": {
7+
"location": {
8+
"lon": -2.235143,
9+
"lat": 53.482358
10+
},
11+
"distance": "100mi",
12+
"field": "geo"
13+
},
14+
"sort": [
15+
{
16+
"by": "geo_distance",
17+
"field": "geo",
18+
"unit": "mi",
19+
"location": {
20+
"lon": -2.235143,
21+
"lat": 53.482358
22+
}
23+
}
24+
]
25+
}'

modules/search/pages/child-field-options-reference.adoc

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,14 +54,17 @@ If you remove the child field from the index, it cannot appear in search results
5454
|[[store]]Store a|
5555

5656
To store the values from the field in the index and return them in search results, select *Store*.
57-
This increases your index's size and indexing time.
57+
This increases your index's size and indexing time.
58+
59+
You can return the values from this field when you include xref:search-request-params.adoc#fields[the fields array] in a Search query.
5860

5961
To remove the field's values from the index, clear *Store*.
6062

6163
|Include in _all field a|
6264
6365
The `_all` field is a composite field that has the content from multiple fields in an index.
64-
It allows searches to query the content of a field without specifying the field's name.
66+
It allows searches to query the content of a field without specifying the field's name.
67+
This option increases your index's size.
6568
6669
To include this field in the `_all` field, select *Include in _all field*.
6770

modules/search/pages/create-child-field.adoc

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,9 @@ To add or remove a child field from a Search index with the Couchbase {page-ui-n
3333
. Click *insert child field*.
3434
. [[field]]In the *Field* field, enter the name of a field in your documents that you want to add or remove from the index.
3535
+
36-
NOTE: The field must contain either a single value or an array. If the field contains a JSON object, xref:create-child-mapping.adoc[create a child mapping] instead.
36+
NOTE: The field must contain either a single value or an array.
37+
If the field contains a JSON object, xref:create-child-mapping.adoc[create a child mapping] instead.
38+
Field names must not contain periods (`.`).
3739
. In the *Type* list, select the data type for the field.
3840
+
3941
For more information about the available data types, see xref:field-data-types-reference.adoc[].

modules/search/pages/create-custom-analyzer.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,12 @@
22
:page-topic-type: guide
33
:page-ui-name: {ui-name}
44
:page-product-name: {product-name}
5+
:page-aliases: fts:fts-index-analyzers.adoc
56
:description: Create a custom analyzer with the Couchbase {page-ui-name} to modify the input text from a Search query or Search index and improve search results.
67

78
[abstract]
89
{description}
10+
For more information about analyzers, see xref:customize-index.adoc#analyzers[].
911

1012
== Prerequisites
1113

modules/search/pages/create-custom-date-time-parser.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
:page-topic-type: guide
33
:page-ui-name: {ui-name}
44
:page-product-name: {product-name}
5+
:page-aliases: fts:fts-date-time-parsers.adoc
56
:description: Create a custom date/time parser with the Couchbase {page-ui-name} to tell the Search Service how to process a new date/time format.
67

78
[abstract]

modules/search/pages/create-quick-index.adoc

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
:page-topic-type: guide
33
:page-ui-name: {ui-name}
44
:page-product-name: {product-name}
5+
:page-aliases: fts:fts-creating-index-from-UI-quick-editor.adoc
56
:description: Use the Quick Index editor in the Couchbase {page-ui-name} to create a Search index.
67

78
[abstract]
@@ -45,6 +46,9 @@ You cannot have 2 indexes with the same name inside the same bucket and scope.
4546
. In the second *Keyspace* list, select the scope where you want to create the index.
4647
. In the third *Keyspace* list, select the collection where you want to create the index.
4748
. In the *Select Fields* box, click a field in the document that you want to add to the index.
49+
+
50+
TIP: You can randomly select a new document from your chosen keyspace by clicking btn:[Refresh] above the *Select Fields* display.
51+
4852
. In the *Type* list, select the field's data type.
4953
+
5054
For more information about the available data types, see xref:field-data-types-reference.adoc[].
@@ -61,4 +65,5 @@ You can xref:customize-index.adoc[customize your index] with the standard Search
6165

6266
CAUTION: If you edit your Search index with the xref:create-search-index-ui.adoc[standard editor], you cannot return to Quick Mode and keep any advanced settings.
6367

64-
To run a search and test the contents of your Search index, see xref:simple-search-ui.adoc[] or xref:simple-search-rest-api.adoc[].
68+
To run a search and test the contents of your Search index, see xref:simple-search-ui.adoc[] or xref:simple-search-rest-api.adoc[].
69+
You can run a search before *Indexing progress* reaches 100% and return partial results.

0 commit comments

Comments
 (0)