AnsweredAssumed Answered

Check PI Tag Exist

Question asked by hiella on Aug 28, 2018
Latest reply on Aug 29, 2018 by hiella



I've been developing a Java application to access PI OLEDB data. One task is to check if the stored tag names are correct--or if some specific tags exist.


Now I have the server: localhost, the data source: and the tag name--string "tagname1". How should I check if this tag exist?


I've tried:


1. Use SQL command "select value where tag = 'tagname1'", but it always returns "invalid column: value". I tried adding "from piarchive..pimax" at the end but it says syntax error near "from", and I actually do not know if table piarchive..pimax is the correct one to check.


2. Use PIServer and PIPoint functions like shown in this discussion: how to find that pi tag exists or not ?  but the thing is I don't know which library/reference to import (or need to download) so my Java does not recognize these classes, or TryFindPIPoint method.


Any ideas?


Thank you,