Forum Discussion

Martin74's avatar
Martin74
Icon for Helper I rankHelper I
5 years ago
Solved

Import from SQL after changing in advanced editor very slow

Hello Everyone,

 

Just a simple query which I use to get some data. After changing the sensors, the specified path which is comming from the BMS system of course also results in another string in SQL.

 

To get the data, I had to change the string in the advanced editor. After this the import is very slow, a refresh takes the same time to complete (about 5-7 minutes).

 

I set up a new file with the same (new) query, this is super fast. So my conlcusion; there must be something in the former file.

 

Below the query I use, the only change I made you can see between old en new.

 

Al the other templates, files etc I made with a lot of more (complex) data works fine as usual (nothing changed). It's not a big issue, but I'm wondering what causes the problem of a very slow import. Anyone a idea?

 

SELECT [PointName]
,[UTCDateTime]
,[ActualValue]
FROM [JCIHistorianDB].[dbo].[RawAnalog]
WHERE UTCDateTime > DATEADD(MONTH, -3, GETDATE())
Old: AND PointName LIKE '%TT1-Kunst%' OR PointName LIKE '%MT1-Kunst%'

New: AND PointName LIKE '%TT1-Ruimtetemp Kunst%' OR PointName LIKE '%MT1-Ruimtevocht Kunst%'

4 Replies