Skip to main content

system.kanoa.event.updateCountEvent

This function requires KanoaOPS module

Description

Updates a count value in the counterEvent table. If it can't find a value at the timestamp, it will add a count value.

Syntax

updateCountEvent(counterId, deltaValue, tStamp, userId=None)
  • Parameters
      counterId - Counter ID.
      deltaValue (float) - Delta value.
      tStamp (datetime) - Timestamp.
      userId (int) - User ID.
  • Returns
    Records modified (int).
  • Code Example

    # Example Usage:
    counterId = 123
    deltaValue = 5.0
    tStamp = timestamp
    userId = 999
    system.kanoa.event.updateCountEvent(counterId, deltaValue, tStamp, userId)