syntax error: SELECT COUNT(id) AS total FROM counter