1、优化查询语句
a. ORDER BY 优化
- 避免使用排序 [尽量使用范围查询替代]
- 使用索引避免排序
b. LIMIT 查询优化
2、特性
a.json
SELECT c->>”$.name” AS name FROM jemp WHERE g > 2 ORDER BY c->”$.name”;
select json_unquote(json_extract(
jemp
.c
,’$.name’)) ASc->>"$.name"
fromjemp
where (jemp
.g
> 2) order by json_extract(jemp
.c
,’$.name’);
发表回复