SELECT
    availability.id,
    availability.userId,
    availability.startTimestamp,
    availability.endTimestamp,
    availability.comment
FROM availability
WHERE
    availability.userId = $1
    AND availability.starttimestamp::date = $2
ORDER BY availability.starttimestamp;
