第39讲 perfetto 自动化之如何写sql查询语句|极客笔记-凯发k8手机登录

本讲是android camera性能分析专题的第39讲,我们介perfetto 自动化之如何写sql查询语句。

更多资源:

资源 描述
在线课程
知识星球 星球名称:深入浅出android camera
星球id: 17296815
wechat 极客笔记圈

sql基本查询语句

查询所有列的数据

select * from thread

查询指定列的数据

select name as name, tid as tid from thread

限制查询结果数量

select * from thread limit 5

对查询结果进行分组

select name from process group by name

对查询结果进行排序

select * from process order by pid desc
select * from process order by pid asc

sql条件查询语句

基本条件查询

select * from process where name='/system/bin/cameraserver'
select * from process where name in ('com.android.camera2', '/system/bin/cameraserver')

模糊条件查询

select * from process where name like '�m%'

sql 条件运算符

sql 条件运算符

sql多表查询

语法:

select column1, column2, ...
from tablea
join tableb on condition;

sql多表查询

例子:查询slice name为frame capture所在的进程名和pid:

select slice.name, process.pid, process.name
from slice
join process_track on slice.track_id = process_track.id
join process using(upid)
where slice.name = 'frame capture'
group by process.name

等价于

select slice.name, process.pid, process.name
from slice
join process_track on slice.track_id = process_track.id
join process on process_track.upid = process.upid
where slice.name = 'frame capture'
group by process.name

camera课程

python教程

java教程

web教程

数据库教程

图形图像教程

办公软件教程

linux教程

计算机教程

大数据教程

开发工具教程

android camera性能分析

网站地图