# system.alarm.queryStatus与数据库中的记录不同步

**URL:** <https://forum.inductiveautomation.com/t/system-alarm-querystatus/73692>\
**Category:** Ignition\
**Tags:** ignition80, perspective\
**Created:** [May 14, 2023, 3:50pm UTC](https://forum.inductiveautomation.com/t/system-alarm-querystatus/73692 "2023-05-14T15:50:06Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![justinedwards.jle](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/justinedwards.jle/32/37854_2.png) [@justinedwards.jle](https://forum.inductiveautomation.com/u/justinedwards.jle)\
**Post date:** [May 14, 2023, 4:43pm UTC](https://forum.inductiveautomation.com/t/system-alarm-querystatus/73692/3 "2023-05-14T16:43:55Z")

</div>

quertStatus returns an list of alarms, so to get the IDs, you will need to iterate through the list and get them:

```auto
state = ['ActiveUnacked']
alarms = system.alarm.queryStatus(state = state)
for alarm in alarms:
	print alarm.id

```

Here is a tutorial that details how to get the other alarm properties in this manner as well:

> [@Print notes of acknowledged alarms](https://forum.inductiveautomation.com/t/print-notes-of-acknowledged-alarms/69430/3):
>
> If you want to get the information directly from the selected alarms in the alarm status table, here is a guide to doing it. Currently, there are 23 properties that show up in the standard alarm status table model. The columns are indexed 0 through 22, and each specific column retains its specific model index no matter how the columns are arranged or rearranged in the table. Here is a map of the columns: # Model Index Column Name # 0 ackNotes # 1 Ack Time # 2 Ack'ed By # 3 …

---

_[View the full topic](https://forum.inductiveautomation.com/t/system-alarm-querystatus/73692)._
