/lot.js:137
var [lottery] = await msql.execute("SELECT lottery.tickets, COUNT(tickets.*) AS `count`, COUNT(DISTINCT tickets.user_id) AS `users` FROM lottery INNER JOIN tickets ON lottery_id = ? WHERE id = ?", [msg.id, msg.id]);
^^^
SyntaxError: Unexpected identifier