CREATE VIEW tcs.meter_data_eb2 AS
select ar.created_date AS created_date,
p.id AS parameter_id,
p.parameter_name AS parameter_name,
ar.parameter_value AS parameter_value,
m.meter_primary_id AS meter_id,
m.meter_name AS meter_name
m.meter_code As meter_code
from tcs.parameter_values_archieve ar
inner join tcs.parameter_master p on p.id = ar.parameter_id
inner join tcs.meter_primary_master m on m.meter_primary_id = ar.meter_id
inner join tcs.meter_master mm on mm.meter_primary_id = m.meter_primary_id;
这个查询有什么问题?
它给出的错误:
您的 SQL 语法有错误;检查与您的 MySQL 服务器版本相对应的手册,以在第 8 行的“m.meter_code Asmeter_code from tcs.parameter_values_archieve ar inner join tc”附近使用正确的语法