发表于:2002-10-31 10:54:00
1楼
以下的例子表示的是tag1和tag2两个模拟量同时显示相关的一些信息的写法:
SELECT TagName, DateTime = convert(varchar, DateTime, 113), Value
FROM v_AnalogHistory
WHERE TagName in (‘tag1’, ‘tag2’)
AND DateTime >= StartDate
AND DateTime <= EndDate
ORDER BY DateTime ASC