Skip to content

Commit bd369f7

Browse files
committed
Fix initialization error
1 parent d5c9d91 commit bd369f7

File tree

1 file changed

+19
-12
lines changed

1 file changed

+19
-12
lines changed

x-pack/plugin/esql/qa/testFixtures/src/main/resources/extract-snippets-function.csv-spec

Lines changed: 19 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -6,26 +6,40 @@ extractSnippetsWithField
66
required_capability: extract_snippets_function
77

88
// tag::extract-snippets-with-field[]
9+
FROM books
10+
| EVAL snippets = extract_snippets(description, "crowning achievement", 1, 25)
11+
// end::extract-snippets-with-field[]
12+
| KEEP book_no, author, title, snippets
13+
| SORT book_no
14+
| LIMIT 1
15+
;
16+
17+
// tag::extract-snippets-with-field-result[]
18+
book_no:keyword | author:text | title:text | snippets:keyword
19+
1211 | Fyodor Dostoevsky | The brothers Karamazov | achievement of perhaps the
20+
// end::extract-snippets-with-field-result[]
21+
;
22+
23+
extractSnippetsWithMatch
24+
required_capability: extract_snippets_function
25+
926
FROM books
1027
| WHERE MATCH(description, "hobbit")
1128
| EVAL snippets = extract_snippets(description, "hobbit", 1, 25)
12-
// end::extract-snippets-with-field[]
1329
| KEEP book_no, author, title, snippets
1430
| SORT book_no
1531
| LIMIT 5
1632
;
1733

18-
// tag::extract-snippets-with-field-result[]
1934
book_no:keyword | author:text | title:text | snippets:keyword
2035
1463 | J. R. R. Tolkien | Realms of Tolkien: Images of Middle-earth | appropriate passage from The Hobbit
2136
2301 | John Ronald Reuel Tolkien | Smith of Wootton Major & Farmer Giles of Ham | beloved author of THE HOBBIT
2237
2675 | J.R.R. Tolkien | The Lord of the Rings - Boxed Set | Bilbo Baggins is a hobbit
2338
2714 | J. R. R. Tolkien | Return of the King Being the Third Part of The Lord of the Rings | the story begun in The Hobbit
2439
2936 | John Ronald Reuel Tolkien | Fellowship of the Ring 2ND Edition | into the hands of the hobbit
25-
// end::extract-snippets-with-field-result[]
2640
;
2741

28-
extractMultipleSnippetsWithField
42+
extractMultipleSnippetsWithMatch
2943
required_capability: extract_snippets_function
3044

3145
FROM books
@@ -45,7 +59,7 @@ book_no:keyword | author:text | title:text
4559
;
4660

4761

48-
extractMultipleSnippetsWithFieldMvExpand
62+
extractMultipleSnippetsWithMatchMvExpand
4963
required_capability: extract_snippets_function
5064

5165
FROM books
@@ -83,10 +97,3 @@ book_no:keyword | author:text | title:tex
8397
2883 | William Faulkner | A Summer of Faulkner: As I Lay Dying/The Sound and the Fury/Light in August (Oprah's Book Club) | null
8498
3293 | Danny Faulkner | Universe by Design | null
8599
;
86-
87-
88-
extractSnippetsWithDefaultNumSnippetsAndLength
89-
required_capability: extract_snippets_function
90-
91-
extractSnippetsCalledMultipleTimes
92-
required_capability: extract_snippets_function

0 commit comments

Comments
 (0)