Re: template {% url } tag syntax

2017-02-26 Thread Carsten Fuchs
Hi Richard, Am 27.02.2017 um 04:01 schrieb Richard Belew: {%url 'djggApp/guest'guest.guestId 'update'%} but this generates a /NoReverseMatch/ error /Reverse for 'djggApp/guest' with arguments '(1, u'update')' and keyword arguments '{}' not found. 0 pattern(s) tried: []/ In the {% url %},

Re: Multiple Databases

2017-02-26 Thread Dylan Reinhold
It is going to use the database named default. Checkout the doc on using mutiple DBs https://docs.djangoproject.com/en/1.10/topics/db/multi-db/ Dylan On Sun, Feb 26, 2017 at 11:17 PM, Luvpreet Singh wrote: > Hi everyone, > > I am using 2 databases in my django app. One

Multiple Databases

2017-02-26 Thread Luvpreet Singh
Hi everyone, I am using 2 databases in my django app. One is default sqlite and second is postgre. Now, I make a simple model named Check1 in my app, having only title attribute. class Check1(models.Model): title = models.CharField(max_length=100) Now, in my shell, >> from

Re: template {% url } tag syntax

2017-02-26 Thread Richard Belew
i should also probably say that the url spec is in the djggApp's specific urls.py file, included in the project's urls.py my primary reference is the url tag reference doc but i must not be composing its arguments correctly?

template {% url } tag syntax

2017-02-26 Thread Richard Belew
i have a hardwired URL in my template: /djggApp/guest/{{ guest.guestId }}/update/ that successfully matches against this url pattern: url(r'^guest/(\d+)/update$', login_required(views.GuestUpdate.as_view()), name='updateGuest'), now i am trying to replace the template code with a more

Re: group by 3 fields

2017-02-26 Thread Larry Martell
On Sun, Feb 26, 2017 at 5:05 PM, wrote: > > > On Sunday, February 26, 2017 at 12:55:17 PM UTC+1, Daniel Roseman wrote: >> >> >> You should explain what you want to achieve. Grouping is pointless on its >> own. In any case, when working with an ORM like Django's it is

Re: group by 3 fields

2017-02-26 Thread Larry Martell
On Sun, Feb 26, 2017 at 6:55 AM, Daniel Roseman wrote: > On Sunday, 26 February 2017 11:11:39 UTC, larry@gmail.com wrote: >> >> Order by is not the same as group by. Group by does aggregation >> > > You should explain what you want to achieve. Grouping is pointless on

Re: Flattening model relationships (in APIs)

2017-02-26 Thread marcin . j . nowak
On Tuesday, February 21, 2017 at 8:13:25 PM UTC+1, Ankush Thakur wrote: > > If the relationship chain was even deeper, there would be even more > nesting, which I feel isn't great for API consumers. What is the best > practice here to put state and country at the same level as the city? >

Re: group by 3 fields

2017-02-26 Thread marcin . j . nowak
On Sunday, February 26, 2017 at 12:55:17 PM UTC+1, Daniel Roseman wrote: > > > You should explain what you want to achieve. Grouping is pointless on its > own. In any case, when working with an ORM like Django's it is generally > not helpful to think in terms of SQL. > -- > DR. > Also

Re: Who can help me installing Django on windowsX machine?

2017-02-26 Thread Mike Dewhirst
On 27/02/2017 5:00 AM, Asifuzzaman Bappy wrote: hello Django community, I'm a new comer here. need some help with my installation of Django on my machine. I have python 2.7 already installed on my computer. but it seems like i cant pull this off. Open up a command prompt ... -> pip install

Who can help me installing Django on windowsX machine?

2017-02-26 Thread Asifuzzaman Bappy
hello Django community, I'm a new comer here. need some help with my installation of Django on my machine. I have python 2.7 already installed on my computer. but it seems like i cant pull this off. I know, what you are thinking at this point. why windows?? right?? but for the time being

Re: Sometimes Channels does not work properly

2017-02-26 Thread Andrew Godwin
Don't worry about the redis traffic, that's normal. Instead, what would help is: * Knowing the versions you have of django, channels, Daphne, asgiref and asgi_redis * Seeing the console output from the server (and a worker if you are running one, but you don't if you are using runserver) *

Sometimes Channels does not work properly

2017-02-26 Thread Mohammad Ghasemi
Hello everyone, I use channels for some real time systems like notifications and chat. While I've set it right, but it still does not work properly. Some times client connects but does not receive any message (I mean client receives absolutely no message). Some other times everything works

Add new record in filtered list in the admin interface

2017-02-26 Thread Roberto Russi
In the Admin interface when I add a new record to a filtered list and submits it, I come back in a no longer filtered list unlike when I edit a record. How can I fix this problem? -- You received this message because you are subscribed to the Google Groups "Django users" group. To

Re: group by 3 fields

2017-02-26 Thread Daniel Roseman
On Sunday, 26 February 2017 11:11:39 UTC, larry@gmail.com wrote: > > Order by is not the same as group by. Group by does aggregation > > You should explain what you want to achieve. Grouping is pointless on its own. In any case, when working with an ORM like Django's it is generally not

Re: group by 3 fields

2017-02-26 Thread Larry Martell
Order by is not the same as group by. Group by does aggregation On Sun, Feb 26, 2017 at 5:30 AM chris rose wrote: > there is a model meta option called ordering. you can specify a list of > fields to order by > > docs found at: >

Re: group by 3 fields

2017-02-26 Thread chris rose
there is a model meta option called ordering. you can specify a list of fields to order by docs found at: https://docs.djangoproject.com/en/1.10/ref/models/options/#ordering i have only used this in the admin -- You received this message because you are subscribed to the Google Groups