Aspentech infoplus 21 download R

128 views Asked by At

I use an R code to download datas from Aspentech IP21 database. Is there a way to know if a tag is in "bad" status or in "good" status. It would be useful, otherwise I get 0 (zeros) when a variable is bad, but I don't know if it really is zero. Thanks.

1

There are 1 answers

2
Madgui On

It depends greatly of what you mean by tag, and where do your data comes from.
For most of the values, quality (good on else) is not defined on tag level, but rather on each value:

  • on record from IP_AnalogDef definition, check for field IP_TREND_QSTATUS, or QSTATUS(IP_TREND_VALUE)
  • on pseudo-table HISTORY and AGGREGATE, it's field STATUS

BUT if your tag comes from a CIMIO for OPC interface, you can query the status of the related Get Transfer record:
select "IO_VALUE_RECORD&&FLD"->NAME tagname, IO_DATA_STATUS, IO_DATA_STATUS_DESC from "TransferDefName" where tagname = 'NameOfYouTag'
Where TransferDefName can be IoGetDef, IoLongTagGetDef, or IoLLTagGetDef
I hope it helps.