mirror of
https://github.com/MariaDB/server.git
synced 2025-11-01 11:26:11 +01:00
Analysis: While writing the view to .FRM file, we check the datatype of each column and append the appropriate type to the string (which will be written to the frm). This is where the conversion from JSON to longtext happens because that is how it is stored internally. Now, while SELECT, when the frm is read it has longtext instead of JSON which also results in changing the handler type. Since the handler types dont match, m_format_json becomes false for that specific column. Now, when filling the values, since the format is not json, it does not get added in the result. Hence the output is NULL. Fix: Before writing the view to the FRM file, check if the datatype for the column is JSON (which means the m_format_json will be true). If it is JSON append JSON. |
||
|---|---|---|
| .. | ||
| r | ||
| t | ||