Re: SQL query to django

2021-10-09 Thread carlos
ok, try this but is only idea (i don't is working) from django.db.models import Count result = (YY.objects .values('time_frame','status') .annotate(timecount=Count('time_frame')) .order_by('status') ) read this for understand

Re: When you app depends on a custom user model

2021-10-09 Thread Harouna Diallo
I agree Le sam. 9 oct. 2021 à 16:02, bnmng a écrit : > Django "strongly recommends" you create custom user, and in your apps you > can refer to the custom user with "settings.AUTH_USER_MODEL" or with > get_user_model(). > > Here's the problem. If you develop an app which refers to the custom >

When you app depends on a custom user model

2021-10-09 Thread bnmng
Django "strongly recommends" you create custom user, and in your apps you can refer to the custom user with "settings.AUTH_USER_MODEL" or with get_user_model(). Here's the problem. If you develop an app which refers to the custom user, the migrations won't be portable because even if you

Re: Re:

2021-10-09 Thread Sebastian Jung
Have you truncate table auth_users? ola neat schrieb am Sa., 9. Okt. 2021, 16:00: > But it working perfectly offline > > On Sat, Oct 9, 2021, 14:26 Ahmad Abdulnasir Shuaib < > ahmadabdulnas...@gmail.com> wrote: > >> Check your models, you may have unique_together option enabled. >> >> On Sat,

Re: Re:

2021-10-09 Thread ola neat
But it working perfectly offline On Sat, Oct 9, 2021, 14:26 Ahmad Abdulnasir Shuaib < ahmadabdulnas...@gmail.com> wrote: > Check your models, you may have unique_together option enabled. > > On Sat, Oct 9, 2021, 12:09 PM Sebastian Jung > wrote: > >> Hello, >> >> No only friends get social media

Re: Re:

2021-10-09 Thread Ahmad Abdulnasir Shuaib
Check your models, you may have unique_together option enabled. On Sat, Oct 9, 2021, 12:09 PM Sebastian Jung wrote: > Hello, > > No only friends get social media or WhatsApp. > > I think yoz need a experience developer. Try to get one developer on > upwork. I have no expeeience with

SQL query to django

2021-10-09 Thread Eugene TUYIZERE
Dear all, I have a table let call it *YY*. Some fields in this table are status, time_frame, etc. time frame is in terms of years and status are Not started, In progress and Completed. I want to display all services Not started, in progress and completed in each year. And at the end to display