What This Table Is

The sysevent table is ServiceNow's asynchronous event queue, storing events created by gs.eventQueue() for background processing. These events drive notifications, script actions, and flow triggers without blocking the current transaction. Every time you fire an event with gs.eventQueue('record.insert', current), a record lands here temporarily.

Owned by the Platform module, this table supports ServiceNow's event-driven architecture end-to-end. Events get queued here, then consumed by event processors running in the background. The entire notification system, many automated workflows, and custom integrations depend on this queue functioning properly.

The sysevent table doesn't extend any parent and has no child tables. It's a standalone queue table with a unique lifecycle—records get created and automatically deleted after processing. This makes it fundamentally different from typical ServiceNow tables where records persist.

In large enterprises, this table processes thousands of events daily but typically maintains a small record count because events are consumed quickly. Performance remains good even with high throughput since the table is optimized for rapid insertion and deletion rather than complex queries.

When You'll Script Against This Table

You'll rarely query sysevent directly—most interaction happens through gs.eventQueue() in Business Rules, Script Includes, and scheduled jobs. You'll script against it when troubleshooting event processing, building monitoring tools, or creating custom event processors. Most debugging happens in Script Background or scheduled jobs.

Access requires admin role or specific event management roles. The table has restrictive ACLs since event data can contain sensitive information from any record type. Global scope scripts have full access, but scoped applications have limited event creation rights.

  • Monitor event backlogs during system issues
  • Debug why notifications or flows aren't triggering
  • Create custom event processors for specific event names
  • Build dashboards showing event processing health
  • Purge old events that failed to process
  • Analyze event patterns for performance optimization
  • Queue custom events for batch processing workflows

Table Gotchas

⚠️

Events are automatically deleted after processing. Your dev instance will often show zero events even when the system is actively processing them. This makes debugging timing-sensitive.

⚠️

The parm1 and parm2 fields store serialized objects, not plain text. Always use gs.eventQueue() to create events rather than inserting records directly.

  • The state field uses choice values: 0=Ready, 1=Processing, 2=Processed, 3=Error. Most events you'll see are state=0 waiting for processing.
  • Events can get stuck in state=1 (Processing) if the processor crashes. These orphaned events won't auto-retry and need manual cleanup.
  • The instance field tracks which node is processing the event in clustered environments. Useful for debugging node-specific issues.
⚠️

Querying large date ranges can be expensive since events are indexed primarily for quick processing, not historical analysis. Always include state filters and limit result sets.

  • The claimed_by field shows which background process claimed the event. Empty means unclaimed and available for processing.
  • Events older than 7 days get automatically purged regardless of state. Don't rely on this table for audit trails or long-term event history.
Free Newsletter

Enjoying this? Get one deep-dive per week.

Join 1,000+ ServiceNow pros — scripts, GlideRecord patterns, Flow Designer techniques, and career moves. Free.

No spam · Unsubscribe anytime

The sysevent table connects to sys_script_action through the event name—script actions subscribe to specific event names and execute when matching events arrive. You'll often query both tables together when debugging why script actions aren't firing. The sysevent_email_action table also processes events for notification emails.

Flow triggers in the sys_trigger table can subscribe to events, making sysevent a bridge between traditional scripting and Flow Designer. The sys_log table captures errors during event processing, so you'll cross-reference both when troubleshooting failed events. Since events can reference any table record through table and instance fields, you might join to any table in the system depending on what triggered the event.