surrogate pair in json is not supported by MySQL, but supported by TiDB
- Dominant language
- Go
- Stars
- 40.5k
- Forks
- 6.2k
- PR merge metrics
- PR metrics pending
Description
## Bug Report
Please answer these questions before submitting your issue. Thanks!
### 1. Minimal reproduce step (Required)
```
select json_extract("\"\\ud800\"", "$");
```
### 2. What did you expect to see? (Required)
```
mysql> select json_extract("\"\\ud800\"", "$");
ERROR 3141 (22032): Invalid JSON text in argument 1 to function json_extract: "The surrogate pair in string is invalid." at position 1.
```
### 3. What did you see instead (Required)
```
mysql> select json_extract("\"\\ud800\"", "$");
+----------------------------------+
| json_extract("\"\\ud800\"", "$") |
+----------------------------------+
| "�" |
+----------------------------------+
1 row in set (0.00 sec)
```
### 4. What is your TiDB version? (Required)
Contributor guide
Assessment
This issue has not been assessed yet.