sqlboiler
sqlboiler copied to clipboard
Gen shortcut for `COUNT(DISTINCT column_name)`
There's Count method that is generated for a table:
Count(ctx context.Context, exec boil.ContextExecutor) (int64, error) // performs COUNT(*)
It'd be useful to have CountDistinct method:
CountDistinct(ctx context.Context, exec boil.ContextExecutor, column string) (int64, error) // performs COUNT(DISTINCT column)
If you send in a PR, I'll be happy to review.