Closed flycash closed 3 years ago
Please check existing issues first to avoid duplication and answer the questions below before submitting your issue.
We need to support major aggregate functions, check MySQL aggregate functions
We only support a few of them. (Please state use cases, what problem will this feature solve?)
Here is an example:
// As specifies the alias func (Aggregate) As(alias string) Aggregate { panic("implement me") } // Avg represents AVG func Avg(c string) Aggregate { panic("implement") }
You need to think about this:
New().Select(Columns("Id"), Avg("Age").As("avg_age")).From(&TestModel{}) // "SELECT `id`, AVG(`age`) as `avg_age` FROM `test_model`;",
(Please describe your proposed design/solution, if any)
(Other possible options for solving the problem?)
It relies on #10
(Paste any relevant logs - please use code blocks (```) to format console output, logs, and code as it's very hard to read otherwise.)
(If you can, link to the line of code that might be helpful to explain the context)
English Only
Please check existing issues first to avoid duplication and answer the questions below before submitting your issue.
Use case(s)
We need to support major aggregate functions, check MySQL aggregate functions
We only support a few of them. (Please state use cases, what problem will this feature solve?)
Proposed Solution
Here is an example:
You need to think about this:
(Please describe your proposed design/solution, if any)
Alternatives Considered
(Other possible options for solving the problem?)
Additional Context
It relies on #10
(Paste any relevant logs - please use code blocks (```) to format console output, logs, and code as it's very hard to read otherwise.)
(If you can, link to the line of code that might be helpful to explain the context)