1、建表
1)、创建超级表
CREATE STABLE IF NOT EXISTS vihicle_location (
ts timestamp,
lon double,
lat double,
speed float,
direction int,
altitude float
) TAGS (
vin varchar(64),
plate_number varchar(64)
);
- ts 时间戳
- lon 经度
- lat 纬度
- speed 速度
- direction 方向
- altitude 海拔
标签
- vin 车辆唯一编号
- plate_number 车牌号
2)、创建子表
CREATE TABLE IF NOT EXISTS lv123456
USING vihicle_location (
vin,
plate_number
) TAGS (
"lv123456",
"津HJN609"
);
