Description
New multi-byte character aware versions of:{{ length, lpad, rpad, substr }}and{{ position}} have been added. They are all prefixed with "MB_". The multi-byte character aware functions return/accept character counts/positions rather than byte values.
(All variants of SUBSTR & POSITION exist - MB_SUBSTR, MB_SUBSTR0, MB_SUBSTR1, MB_POSITION, MB_POSITION0, MB_POS0, MB_POSITION1, MB_POS1 - though I note we don't document other than the base variants.)
They should be added under https://docs.couchbase.com/server/current/n1ql/n1ql-language-reference/stringfun.html and should be referenced in the documentation for their byte-wise counterparts. e.g. https://docs.couchbase.com/server/current/n1ql/n1ql-language-reference/stringfun.html#fn-str-substr should have the descriptions for start_pos and length enhanced to note "This is in bytes not characters" and the overall entry should contain a note to the effect "A character-based variant of this function is MB_SUBSTR." (or similar)
The MB_ variants should note that they will be slower than their byte-wise counterparts.