No Displaypath with system.alarm.queryJournal?

I am trying to view the alarm journal and limit its results to just the most 5 recent entries. I didn’t see an option for that on the official alarm journal object so I wrote a script that would query the alarm journal and then trim the list down to five entries.

It worked, but my display path is empty, for some reason, the provider, tag path and alarm name have all been shoved into “Source” like this

prov:default:/tag:Bays/Bay_1/Chiller Status:/alm:Chiller Faulted

I checked the database and sure enough, DisplayPath is empty and everything is thrown together in the Source column. Does anyone know why on earth that would be? It seems like it would just make performing selects more difficult as you now have to parse strings to get information that should be stored in a unique column :scratch: (Using Ignition 7.9.1)

If the display path is not configured, or is static, then it will not be stored in each record of the journal tables. However, in recent versions of Ignition, the display path can be retrieved from one of the AlarmEvent objects in the returned lists using the member method: getDisplayPathOrSource()

The alarm name is retrieved using: getName()

getSource() will return a fully-qualified path, which can be parsed using the built-in methods of that object:

To get the tag path:

To get the provider: