Hi We are worlds first affordable Python, Django Based Web Developement
Startup.
And can help you in this and related tasks / projects immidiately mere at
$7 per hour.
On Mon, 2 Dec 2019 at 19:13, xiaopeng luo wrote:
> I am new to django ORM, I want query something like this:
>
> input:
> AAA
You need to do some little reading about Django aggregation
https://docs.djangoproject.com/en/2.2/topics/db/aggregation/#topics-db-aggregation
Example
from django.db.models import Max, Count, Sum
Publisher.objects.values('name').annotate(*dcount*=Count('name'))
As seen above you can apply simila
What you want to hear please cear that one..
Thanks
On Mon, 2 Dec 2019, 19:13 xiaopeng luo, wrote:
> I am new to django ORM, I want query something like this:
>
> input:
> AAAfemale1
> AAAfemale2
> BBBmale 1
> BBBmale 3
> AAAmale 2
>
>
>
> output
>
I am new to django ORM, I want query something like this:
input:
AAAfemale1
AAAfemale2
BBBmale 1
BBBmale 3
AAAmale 2
output
AAAfemale3
AAAmale 2
BBBmale 4
Sorry, my english is not good. Thanks for everyone help me.
--
4 matches
Mail list logo