Re: django models

2018-08-07 Thread Gerald Brown
Just delete the code in models.py and run ./manage.py makemigrations and ./manage.py migrate. On Wednesday, 08 August, 2018 01:14 AM, Ramandeep Kaur wrote: My question is that how to delete models in django? -- You received this message because you are subscribed to the Google Groups "Django

Re: Django ORM aggregate Sum function on foreign key

2018-08-07 Thread Gerald Brown
vi is just a variable that I created in my code.  It is just short for visit.  It has NOTHING to do with the vi editor program.  My editor is Geany. I am using the Django ORM to query my database. On Wednesday, 08 August, 2018 01:45 AM, Kidwell Nyatsambo wrote: Hello, Which application /

Re: django models

2018-08-07 Thread Christophe Pettus
> On Aug 7, 2018, at 10:14, Ramandeep Kaur wrote: > > My question is that how to delete models in django? Do you need to delete a model *class*, or a model *instance*? -- -- Christophe Pettus x...@thebuild.com -- You received this message because you are subscribed to the Google Groups

Re: Django ORM aggregate Sum function on foreign key

2018-08-07 Thread Kidwell Nyatsambo
Hello, Which application / program uses vi. I would like to create a schema.sql to use with Python. KN On Mon, Aug 6, 2018 at 4:08 PM, Gerald Brown wrote: > This is how I finally solved my problem!!! > > The following is a copy of my ORM statement: > > Visit.objects.filter(visit_date =

django models

2018-08-07 Thread Ramandeep Kaur
My question is that how to delete models in django? -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this

Live Streaming Video with WebCam OpenCv Python

2018-08-07 Thread Pravin Yadav
*Hello Everyone, I'm using the Live Streaming Video through WebCam. It's storing in .avi format. When i'm playing the Video. I'm not getting the audio of that video. I hope that opencv does not provide the audio features. Kindly let me know if you have any idea. Thanks,* *Please find the below

Re: Where can I place code to read a db table at startup to create an in memory cache?

2018-08-07 Thread B K
Hello Jason, This is a project dealing with Internet of Things/5G. The plan was to cache millions of devices session information in memory for the frequently communicating things and to age out the infrequent things to the database. The in memory search would be done first, If cache hit did

Re: Docs on multiple servers/memcached daemons not clear

2018-08-07 Thread ciaran . courtney
Sorry for double post, didn't realize there was an approval step https://groups.google.com/forum/#!topic/django-users/EZho7Y8KSOw -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it,

Re: How to pass variable dates to a ORM query

2018-08-07 Thread Derek
You'll probably need to post some code snippets; what do these functions' signatures look like and how do they get called? On Tuesday, 7 August 2018 03:43:01 UTC+2, Gerald Brown wrote: > > I have a Django/Python function that creates a Reportab PDF file based on > the current date. Works GOOD.

Docs on multiple servers/memcached daemons not clear

2018-08-07 Thread ciaran . courtney
https://docs.djangoproject.com/en/2.1/topics/cache/#memcached When running a memcached daemon on each server, is it implicitly implied that each memcached daemon should be configured to listen on 0.0.0.0 (default is 127.0.0.1) so that all Django processes can get/set in one big memory pool,

Docs on distributed memcached setup are not clear

2018-08-07 Thread ciaran . courtney
https://docs.djangoproject.com/en/2.1/topics/cache/#memcached Particularly the multiple servers section, which does not detail if all memcached daemons should be configured to listen on all interfaces i.e. 0.0.0.0 So just as a sanity check: Scenario 1: (memcached installed naively ( i.e.

Re: Where can I place code to read a db table at startup to create an in memory cache?

2018-08-07 Thread Jason
What other alternatives have you looked at with caching before this? How long is your cache lifetime, how heavy is your db load, what spikes do you have, what are your bottlenecks. There are two hard things in computer science: cache invalidation, naming > things, and off-by-one errors. >

many to many with added attribute on template

2018-08-07 Thread rvandenbergisfap
Our challenge are as follow: 1. Many to Many link with added attributes. Let me explain: 1. We can capture the link: 2. But actually requires the following: Thus captured an added attribute on the many to many relationship. We connect to SQL SERVER 17 *Models.py* *class

Where can I place code to read a db table at startup to create an in memory cache?

2018-08-07 Thread B K
I would like to read a table from the database at startup time to build an in memory cache for fast data retrieval. Where is the best place to insert this code to run in django? thx bk -- You received this message because you are subscribed to the Google Groups "Django users" group. To

Re: Given source data and destination data (in json format), write a function which will validate whether source data is same as destination data and highlight the differences.

2018-08-07 Thread Derek
This is not a Django issue; try and post on a Python mailing list. (HINT: if you want help with code, then write a function that shows what you have attempted. No one else will actually write your code for you...) On Monday, 6 August 2018 14:16:00 UTC+2, tal...@gmail.com wrote: > > > please do

Re: Learning django

2018-08-07 Thread Derek
https://www.twoscoopspress.com/products/two-scoops-of-django-1-11 (Assuming you don't need the cutting-edge version and, to be honest, I'd think it extremely unlikely that anyone could write a book on a cutting-edge version of *any* software platform ... and I'd be very suspicious of such a