Skip to content

Commit 1c61264

Browse files
committed
Updates by comments
1 parent 99f5f08 commit 1c61264

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

doc/reference/reference_lua/key_def.rst

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,7 @@ to extract or compare the index key values.
264264
265265
tarantool> key_def:validate_key({1000, 'abc', 'xyz'})
266266
---
267-
- error: Invalid key part count (expected [0..2], got 3)
267+
- error: 'Invalid key part count: (expected [0..2], got 3)
268268
...
269269
270270
.. _key_validate_full_key:
@@ -284,6 +284,7 @@ to extract or compare the index key values.
284284
285285
-- Create a rule: key = {1 ('unsigned'), 2 (string)}
286286
-- Validate key {100, "Testuser"}. Returns nothing
287+
-- Validate key ({100}). ER_EXACT_MATCH is raised
287288
288289
tarantool> key_def = require('key_def').new({{fieldno = 1, type = 'unsigned'},
289290
> {fieldno = 2, type = 'string'}})
@@ -294,6 +295,11 @@ to extract or compare the index key values.
294295
---
295296
...
296297
298+
tarantool> key_def:validate_full_key({100})
299+
---
300+
- error: 'Invalid key part count in an exact match: (expected 2, got 1)
301+
...
302+
297303
.. _key_validate_tuple:
298304

299305
.. method:: validate_tuple(tuple)

0 commit comments

Comments
 (0)