Skip to main content

CLOSE_SESSION_SQL

Constant CLOSE_SESSION_SQL 

Source
pub const CLOSE_SESSION_SQL: &str = "
UPDATE sessions SET ended_at = ?1
WHERE session_id = ?2 AND ended_at IS NULL;
";
Expand description

Mark a session as ended (clean transport close). Only updates if not already ended (idempotent).