Jump to content

Pulling Categorical Data with wrong UOM


Go to solution Solved by John Brezovec,

Recommended Posts

I am trying to use data from a tag that utilizes strings (e.g. 'ON', 'OFF', 'FFWD', etc. etc.) but am receiving the below API error. I noticed that the UOM is incorrect and I believe that is why I can't pull this data to work on.
 
Is there a way to ignore the UOM and grab the data from this tag as a list of strings vs. time?
 
# Find the tag 
APC = spy.search({
    "Name" : "/^tag$/",
    "Datasource Name": "source"
})

APC

# Sample calculation
spy.pull(APC)

 

Error encountered, scroll down to view
  ID Type Path Asset Name Time Count Pages Data Processed Result
0 0973736A-F4A7-4DC0-A8C2-758DC0E42B50 StoredSignal xxxx Tags tagTATUS 0 0 0 0 B (503) Service Unavailable - INTERNAL: Client data source exception: Error processing signal request for e5358933-f0b8-11ed-83b3-64d69ab1de78/ba208ed7-859e-49ef-ba59-a822a6d1e2d6 with start: 2024-04-18T19:30:00Z and end: 2024-04-18T20:45:00Z. Cannot convert 'ON' to type Double using UOM 'percent'. Exception: InvalidCastException
 
Seeq API Error: (503) Service Unavailable - INTERNAL: Client data source exception: Error processing signal request for e5358933-f0b8-11ed-83b3-64d69ab1de78/ba208ed7-859e-49ef-ba59-a822a6d1e2d6 with start: 2024-04-18T19:30:00Z and end: 2024-04-18T20:45:00Z. Cannot convert 'ON' to type Double using UOM 'percent'. Exception: InvalidCastException Error found at line 2 in cell 14.
Edited by John Brezovec
Formatting
Link to comment
Share on other sites

  • Seeq Team
  • Solution

You're correct that it looks like this signal has been assigned the improper unit. These errors get raised outside of SPy, so there isn't a way to ignore them in Python. If you try trending this same signal in workbench you should get the same error. This is either a datasource configuration issue or a historian misconfiguration -- I'd suggest raising a support ticket so we can help you track down the source of the issue: https://support.seeq.com/kb/latest/cloud/

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...