register Event

@Modifying(clearAutomatically = true )
@Query(value = "INSERT INTO " + HOST_EVENTS_KEY + " (" + IDENTIFIER_KEY + "," + TYPE_KEY + "," + EVENT_DATE_KEY + "," + HOST_IDENTIFIER_KEY + ") VALUES (" + ":" + IDENTIFIER_KEY + "," + ":" + TYPE_KEY + "," + ":" + EVENT_DATE_KEY + "," + ":" + HOST_IDENTIFIER_KEY + ")", nativeQuery = true )
abstract fun registerEvent(@Param(value = "id") eventId: String, @Param(value = "type") type: String, @Param(value = "event_date") eventDate: Long, @Param(value = "host_id") hostId: String)

Query used to register a new event

Parameters

eventId

The identifier of the event

type

The type of the event

eventDate

The date when the event occurred

hostId

The identifier of the host owner of the event


@Modifying(clearAutomatically = true )
@Query(value = "INSERT INTO " + HOST_EVENTS_KEY + " (" + IDENTIFIER_KEY + "," + TYPE_KEY + "," + EVENT_DATE_KEY + "," + EXTRA_KEY + "," + HOST_IDENTIFIER_KEY + ") VALUES (" + ":" + IDENTIFIER_KEY + "," + ":" + TYPE_KEY + "," + ":" + EVENT_DATE_KEY + "," + ":" + EXTRA_KEY + "," + ":" + HOST_IDENTIFIER_KEY + ")", nativeQuery = true )
abstract fun registerEvent(@Param(value = "id") eventId: String, @Param(value = "type") type: String, @Param(value = "event_date") eventDate: Long, @Param(value = "extra") extra: String, @Param(value = "host_id") hostId: String)

Query used to register a new event

Parameters

eventId

The identifier of the event

type

The type of the event

eventDate

The date when the event occurred

extra

The extra information related to the event

hostId

The identifier of the host owner of the event