How to create a function like Count

2020-05-25 Thread Saurabh Adhikary
I want to create a custom function which will get modified into a sql querry and will work like Count ...i.e. for every row of the queryset -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails

Re: JSON data

2020-05-24 Thread Saurabh Adhikary
data = [{"exped": "MA", "destin": "AL", "count": 2}, {"exped": "MA", "destin": "BS", "count": 1}] mylist = [] for a in data : mylist.append([a['exped'],a['destin'],a['count']]) On Sunday, 24 May 2020 17:16:46 UTC+5:30, HJ wrote: > > hello guys hope you are doing well > > I am trying to m

Additional column in Queryset with condition

2020-05-23 Thread Saurabh Adhikary
column values are not getting passed. Kindly , if you can help find a solution by : - handling the queryset in a better way - writing a query like Count as that is working fine for a similar column (although I know this works on Foreign key, but still if the logic is helped how to write Co

Re: Website slowed down drasticaly

2019-05-06 Thread Saurabh Adhikary
ou roll-back (in test environment) does it fix the > problem? Maybe it is a component that has been updated. Any configuration > changes to your web server? > > 4. If it isn't the database then it's something else. You need to isolate > each part of the system in turn and p

Re: Website slowed down drasticaly

2019-05-03 Thread Saurabh Adhikary
t have a need to look into it yet, but they could help speed up >>> things. >>> I would not suggest it for payment gateway endpoints. If your project is >>> a ERP/CRM type project, it could help you a little to look into it. >>> https://www.spirulasystems.com/blog/

Re: Website slowed down drasticaly

2019-05-02 Thread Saurabh Adhikary
ore walking down this road. >https://pypy.org/ > >5. Try using a different web server. If you are using Apache, try >using nginx. Also use a different wsgi server. If you are using gunicorn, >try with waitress or others. > > > > Regards, > Che

Re: Website slowed down drasticaly

2019-05-02 Thread Saurabh Adhikary
t; Why don't you upgrade Django at least to 1.11? Django 1.8 extended support > ended last year. > > https://www.djangoproject.com/download/ > אורי > u...@speedy.net > > > On Thu, May 2, 2019 at 2:39 PM Saurabh Adhikary > wrote: > >> Hello , >> >>

Website slowed down drasticaly

2019-05-02 Thread Saurabh Adhikary
Hello , I'm using Django version 1.8.1 and Python version 2.7.12 . Suddenly since Feb '19 there has been a drastic decrease in my website's response rate. For sure , there has been some minor increase in the no of hits, but the performance is too bad. Initially , the thought came that the har