Best way to store trouble codes?

I’m collecting trouble codes from machines and trying to figure out the best way to store them in the platform.

Each time I sample, there can be from 0 to N trouble codes in effect. Each of the N trouble codes has 6 number parameters associated with it.

It’s a bit awkward to store them as attributes as my only option is to choose a maximum number of codes to represent, say K. Then I have many attributes code0_param0, code0_param1, code0_param2, code0_param3, code0_param4, code0_param4, code0_param5, code 1_param0, code1_param1 . . . . . all the way up to code codek_param5. It gets messy pretty quickly.

Is there a better way?

Hi @paul_wareham,

Just one question to help me answer for your use case, how are you accessing and using this data? Are you presenting it in a dashboard or exporting it? I was thinking Data Tables may be useful since you always have six attributes and N number of trouble codes, but this will depend on how you are using the data.

Thanks!
Julia

@JuliaKempf we use the data to present on an experience page to show a table active trouble codes as well as a history of recent codes. Additional we can trigger notifications when a code is generated and send a copy of those codes via email or sms.

They don’t represent sensor information so there is no gauge or aggregation used.

Thanks

Paul

@paul_wareham

Have you considered storing them as Events? We just pushed a major update to them. You can associate Events to Devices, add additional metadata, and a complete history of changes.

For more:

That’s an interesting idea. I hadn’t considered that.

Wha do you think would me the Pros and Cons versus other methods?

What do you think @JuliaKempf ?