GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
Already on GitHub? Sign in to your account
You can do GROUP BY (or anything else arbitrary) with the .add() chain:
db.query().select("COUNT(*)").from("messages").add(" GROUP BY user_id").execute();
Just make sure you put a space BEFORE the GROUP BY, as it doesn't do it for you (it will look like "FROM messagesGROUP BY...")
NOT to confuse "add()" with "and()".