浏览代码

增加字段

datasub12_previous
H Vs 1年前
父节点
当前提交
b166c71e33
共有 1 个文件被更改,包括 6 次插入2 次删除
  1. +6
    -2
      HealthMonitor.Service/Resolver/BloodpressResolver.cs

+ 6
- 2
HealthMonitor.Service/Resolver/BloodpressResolver.cs 查看文件

@@ -155,7 +155,10 @@ namespace HealthMonitor.Service.Resolver

#region 插入BP增量值 hm_bloodpress_stats_inc
// 自动建表
var sql = $"INSERT INTO health_monitor.hm_bp_stats_inc_{bp.Serialno.Substring(bp.Serialno.Length - 2)} USING health_monitor.stb_hm_bloodpress_stats_inc TAGS ('{bp.Serialno.Substring(bp.Serialno.Length - 2)}') VALUES(" +
var sql = $"INSERT INTO health_monitor.hm_bp_stats_inc_{bp.Serialno.Substring(bp.Serialno.Length - 2)} " +
$"USING health_monitor.stb_hm_bloodpress_stats_inc " +
$"TAGS ('{bp.Serialno.Substring(bp.Serialno.Length - 2)}') " +
$"VALUES(" +
$"'{bp.LastUpdate:yyyy-MM-dd HH:mm:ss.fff}'," +
$"'{bp.BloodPressId}'," +
$"'{bp.MessageId}'," +
@@ -182,7 +185,8 @@ namespace HealthMonitor.Service.Resolver
$"{duration}," +
$"'{startTime:yyyy-MM-dd HH:mm:ss.fff}'," +
$"'{endTime:yyyy-MM-dd HH:mm:ss.fff}'," +
$"'{string.Empty}')";
$"'{string.Empty}'," +
$"{isHypertension})";

_serviceTDengine.ExecuteInsertSQL(sql);
#endregion


正在加载...
取消
保存