Re: Group by for querysets

2008-05-09 Thread gmacgregor
On May 9, 4:57 pm, Eric Abrahamsen <[EMAIL PROTECTED]> wrote: > (Don't forget to reply to the list...) Apologies... didn't realize I hit "Reply to author" > The documentation for the groupby function is notoriously obscure, but > it's actually simple to use. It generates pairs where the first i

Re: Group by for querysets

2008-05-09 Thread gmacgregor
On May 9, 2:37 pm, gmacgregor <[EMAIL PROTECTED]> wrote: > Something like it is being "considered" but nothing for > sure:http://code.djangoproject.com/ticket/3566 Whoops, I lied: check out the (currently) last comment made by Russ M on the ticket page: "For the be

Re: Group by for querysets

2008-05-09 Thread gmacgregor
On May 9, 1:47 pm, Chris <[EMAIL PROTECTED]> wrote: > Is there a group_by method when getting querysets? Nope... nothing of the sort. You'll have to write raw SQL for that. I'm struggling with the same thing right now. > Check out the following example. > ... > events_by_group = > SportsEvent.o

Re: Django and CSS

2008-04-24 Thread gmacgregor
On Apr 24, 10:49 pm, Rodney Topor <[EMAIL PROTECTED]> wrote: > So, if my project has a directory structure "mysite/templates/app/ > template.html", then in which directory should I place the CSS file? You'll find this thread helpful: http://groups.google.com/group/django-users/browse_thread/thr

Re: Normalized dates

2008-04-15 Thread gmacgregor
On Apr 15, 9:38 am, Mark Reynolds <[EMAIL PROTECTED]> wrote: > I'm looking at this type of issue also. From what I have been reading - > it is normally advised to always keep dates in UTC, and just convert > when needed. I have two functions that I use to convert to the desired > TZ just before

Normalized dates

2008-04-14 Thread gmacgregor
Some of my project app's models have a DateTimeField where the value is UTC while others have EDT/EST values. This is because I populate some models (ie. a blog entry) via django-admin while other data is populated via my flickr/del.icio.us accounts (via django-syncr ). When displaying timestamps

Re: Strange AttributeError when import'ing twitter

2008-02-12 Thread gmacgregor
On Feb 11, 11:47 pm, Collin Grady <[EMAIL PROTECTED]> wrote: > Don't suppose you called your project or app 'twitter' also? Or any > other file on pythonpath? Nope. Nothing but the twitter module goes by that name... Greg --~--~-~--~~~---~--~~ You received this m

Strange AttributeError when import'ing twitter

2008-02-11 Thread gmacgregor
>From my project root I do this: http://dpaste.com/34820/ Yay! I can talk to twitter! All is good with the world! I have a module called tweet.py at project_root/lib/tweet.py. Weird thing is the AttributeError it produces: http://dpaste.com/34821/ What the? I have a custom tag that imports th

Re: starting point?

2007-11-20 Thread gmacgregor
On Nov 20, 3:08 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > thanks! hopefully my webhoster allows all the needed .htaccess stuff. > but it sounds promising... > > how can i figure out if my webhoster uses fastcgi? can this info be > printed with a simple script? Take a look at the docume