f choice
parse this response into some datastructure you can use. For the Django
view end you can use standard python libraries such as simplejson to create
the response(Django includes a recent version of this), and in JavaScript
you can use your favorite library to take the JSON and create a JS
there
> a non-hackish way to accomplish this with the default language?
>
> Regards,
> Chris
> >
>
Easies way would just be to have 2 seperate if statements(using {% ifequal
%} for the second one) and either and and {% include %} so you don't
duplicate all the HTML.
Alex
there
> a non-hackish way to accomplish this with the default language?
>
> Regards,
> Chris
> >
>
You've now sent this message 3 times, you're want to either calm down or fix
your mail client :).
Alex
--
"I disapprove of what you say, but I will defend to the d
was working a
> while back. I did some cleanup - removing img and .js files that
> weren't in use. I've tried to put all that stuff back, but no luck
> and this message isn't very informative ..
>
> Anyway, any hints appreciated.
>
> margie
>
>
>
>
>
&
eeded in order to make
> the AnyModel?.foreingKey_set working with the new custom manager.
>
> Is it correct and/or safe ?
>
> >
>
It would be far easier for you to just create a single custom manager and
then add several methods onto it, instead of having multiple managers.
Alex
--
en/dev/topics/db/managers/#using-managers-for-related-object-access
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
"The people's good is the highest law."--Cicero
--~--~-~--~~~---~--~---
dev/howto/custom-management-commands/ has
instrutions on how to do this, and you can find a few good blog posts on the
ineternet.
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
&
e a somewhat simple case and there seems to be no
> mention of it in the documentation anywhere.
>
> Sean.
>
> >
>
That's not possible, but that doesn't really affect anything, you still have
that accessor available to you, but it does an extra SQL query, that is t
On Mon, Feb 23, 2009 at 3:49 PM, Torsten Bronger <
bron...@physik.rwth-aachen.de> wrote:
>
> Hallöchen!
>
> Alex Gaynor writes:
>
> > On Mon, Feb 23, 2009 at 12:40 PM, sphogan wrote:
> >
> >> [...]
> >>
> >> However, select_related()
ee the method behind the
> madness
>
>
> >
>
The as_* methods are really just meant as quick ways to get started and
having something to display really quickly, iterating over the form is, IMO,
the perfect balance of total control and DRY:
http://docs.djangoproject.com/en/dev/topic
it couldn't get) so that you'd get an error
> message rather than having that error message pass silently.
>
> Errors should never pass silently.
> Unless explicitly silenced.
> ~Zen of Python
>
> Well, I guess I have a project for this week!
> Sean.
>
>
return obj
Just add this method to the ModelForm and you're golden.
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
"The people's good is the highest law."--Cicero
--~--~-~--~~--
x27;utf-8'
> in my settings
>
> Where does the pb come from? I didn't find the answer on this forum.
> thx a lot
>
> Arbi
> >
>
I'm assuming you're on Django 1.0(or newer, if not please let us know), can
you paste what exactly your __unicode__
gt; >
> First of all use self.category.slug so that you don't have to do an extra
query if the local cache is already populated. Next in places you know this
is giong to be an issue when you do your Product query add a call to
select_related('category') this will cause Django to pr
ute_url, you then
> have to remember to always use select_related().
>
> You could even make that automatic by creating a custom default manager
> whose get_query_set() method looked like this:
>
>def get_query_set(self):
> return super(MyManager,
>
advance,
>
> Mathieu
> >
>
If you're going to need to log into another website that you don't have
control over using this password you can do whatever you want to it, but
ultimately you need to be able to restore it to it's plaintext format, which
means you can'
(and other as_xxx
> methods).
>
>
> > similar changes would be needed for as_ul() and as_table()
> >
>
There's already a ticket for this exact item:
http://code.djangoproject.com/ticket/8426 so don't file another one :) .
However if you want this now feel free to
This just takes a path,
> rather than a file object. See:
> http://docs.djangoproject.com/en/dev/ref/models/fields/#filepathfield
> --
> DR.
> >
>
If you want to reference an existing file what you want to do is just
obj.file_field = "file/location.txt"
That just a
gt; proj1.app1.models? I know I could just use dir(), but that gives me
> other stuff beyond just the models defined just within that file.
>
> Jay
>
> --
> Jay Deiman
>
> \033:wq!
>
> >
>
Note that the following uses what is technically an internal:
from django.db
hnique for doing this are template tags, either regular
ones or inclusion tags, James Bennet wrote an excellent blog post on the
subject:
http://www.b-list.org/weblog/2006/jun/07/django-tips-write-better-template-tags/
Alex
--
"I disapprove of what you say, but I will defend to t
hope you are :) ) it's
just a matter of using a MultipleModelChoiceField with a
CheckboxSelectMultiple widget, which does exactly what you want(assuming you
set it up as a many to many field).
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it.&qu
oo", u"Bar"]:
> if qset is None:
> qset = Q(author__iexact=each)
> else:
> qset = qset | Q(author__iexact=each)
>
>
> >
>
You can clean it up slightly, but that strategy is basically what you want
to do:
qset = Q()
for term in ['
qset is None:
> > qset = Q(author__iexact=each)
> > else:
> > qset = qset | Q(author__iexact=each)
> >
>
Kevin, the way IN works at the SQL level basically means that it will be
doing an exact match against each item, which isn't what he want
t. Thanks!
> >
> > On Feb 23, 5:51 pm, Alex Gaynor wrote:
> >
> > > On Mon, Feb 23, 2009 at 5:40 PM, bretro...@gmail.com <
> bretro...@gmail.com>wrote:
> >
> > > > Hello,
> >
> > > > I'd like to send an email when
flects what they've done, or not done. IE, "book foo updated' or
> "book foo unchanged".
>
> Anyway, just curious if others have encountered this.
>
> Margie
> >
> Form's have a method "has_changed" which says whether or not there is
chan
old model admin, use admin.site.unregister(Site) to
remove the old one, create you're own subclass of the current one and
register it like normal, presto!
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." -
> admin.site.register(Site, SiteAdminMod)
>
>
> >
>
Drop the formset = bit and simply provide fields = ['order'] in the
InlineModelAdmin definition.
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
"
.py
> @register.simple_tag
> def show_webstore_user_ratings(user_ratings):
>A = RATING_CHOICES[user_ratings]
>return A[1]
>
> >
>
Perhaps you're looking for this method:
http://docs.djangoproject.com/en/dev/ref/models/instances/#get-foo-display
Alex
--
"I disapprove of wha
ng the
docutils module and the __doc__ attribute on functions, you can see how it
occurs here:
http://code.djangoproject.com/browser/django/trunk/django/contrib/admindocs/views.py
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
&qu
object, it's not
any sort of global, cross request cache.
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
"The people's good is the highest law."--Cicero
--~--~-~--~~~---~--~~
Y
On Thu, Feb 26, 2009 at 6:26 PM, Jason Broyles wrote:
>
> Thanks for the reply. I was talking about using memcache to cache the
> view. If a search changes, will it get the cache or hit the database?
>
> On Feb 26, 6:11 pm, Alex Gaynor wrote:
> > On Thu, Feb 26, 2009 at 6
ings cannot be imported, because
> environment variable %s is undefined." % ENVIRONMENT_VARIABLE)
> ImportError: Settings cannot be imported, because environment variable
> DJANGO_SETTINGS_MODULE is undefined.
>
> Somebody help?
>
> >
> That's probably because D
d also substitute
> my own.
>
> Jack Orenstein
>
>
> >
>
The best way to do HTML rendering of forms(IMO) is by simply iterating over
the fields:
http://docs.djangoproject.com/en/dev/topics/forms/#looping-over-the-form-s-fields.
In my experience
On Thu, Feb 26, 2009 at 9:56 PM, Jack Orenstein wrote:
>
> On Feb 26, 2009, at 9:44 PM, Alex Gaynor wrote:
>
> > On Thu, Feb 26, 2009 at 9:42 PM, Jack Orenstein
> > wrote:
> >
> > Suggestion: Instead of hardwiring formatting into Django, allow
> > attribut
On Thu, Feb 26, 2009 at 10:10 PM, Jack Orenstein wrote:
>
> On Feb 26, 2009, at 10:04 PM, Alex Gaynor wrote:
>
> >
> >
> > On Thu, Feb 26, 2009 at 9:56 PM, Jack Orenstein
> > wrote:
> >
> >
> > > value="m" name="gender&quo
f reverse.
>
> I'm using modpython, django 1.0.2 and python 2.5.2.
>
> Thanks
> >
>
Unfortunately reverse raises stupid error message, it tries prepending your
project name to the search if the original lookup fails, so the error
message doesn't usually look correct. U
ks in advance
>
>
> >
>
You just call it, views are normal python functions, that being said it is
often better to redirect where possible(or sensible).
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
"The people
Of course within `reverse` function there is `resolve` function that parses
path and return view function, positional arguments, and named arguments.
On Fri, Feb 27, 2009 at 2:33 PM, Andrew Ingram wrote:
>
> Hi All,
>
> I'm trying to to build a model which can store a link to any page on
> the s
tirely of swear words.
>
> .
>
> Some days you think you've heard everything. Then someone comes along
> and proves you wrong. :-)
>
> Yours,
> Russ Magee %-)
>
> >
>
Feel free to build your own profanities list though(lord knows Django's is
pretty arbitr
On 2/27/09, MarcoS wrote:
>
> Hi! wondering if someone could point me in the right
> direction with this one:
>
> I'm trying to populate fields in a form with data from database:
> i.e. suppose I've this model:
>
Try using a multiplemodelchoice field with a check
ier solution.
> >
>
You say it needs to be in each view, but if it's just something to put at
the top of each page then where you really need it is in the template
right? So it sounds like you want a template context processor.
Alex
--
"I disapprove of what you say, but I will
On Fri, Feb 27, 2009 at 2:40 PM, Bobby Roberts wrote:
>
> hi all. I have a situation where I have two tables, auctions and
> bids. I need to do a subquery as such:
>
> select distinct id from auctions_auction where Active=1 and id IN
> (select distinct AuctionId_id from auctions_bid where Bidde
. Thanks in advance!
> >
> > Paul
> >
>
> FYI, here is what I am doing now:
>
> return HttpResponseRedirect('/admin/invoice/invoice/%s/' % object_id)
>
> This works, but pretty ugly...
>
> >
>
If you are on 1.0
chetype.classname.
>
> If I remove select_related(), it works like I expect it should, except
> that now the db is hit a bunch of extra times each time through the
> loop. If I remove annotate(), it also works.
>
> Has anyone else
jango source(which will cause it to break for
other models) it's not going to magically work with your new signature. If
you could provide your modified __init__ we could give some suggestions as
to how to make the signature compatible.
Alex
--
"I disapprove of what you say, but I wi
str(user.id), user.email, ip]))
> self.sha = sha1
> self.user = user
>
>
> Vitaly Babiy
>
>
> On Sat, Feb 28, 2009 at 3:41 PM, Alex Gaynor wrote:
>
>>
>>
>> On Sat, Feb 28, 2009 at 3:38 PM, Vitaly Babiy wrote:
>>
>>> I have a model th
e!
> Justin
>
> >
>
I don't have experience with it, but you may also want to checkout Satchmo:
http://satchmoproject.com/trac/timeline it has a great reputation, and very
good docs.
Alex
--
"I disapprove of what you say, but I will defend to the death your
On Sun, Mar 1, 2009 at 10:25 PM, Chris wrote:
>
> On Feb 21, 10:03 am, Alex Gaynor wrote:
> > On Sat, Feb 21, 2009 at 7:48 AM, Chris wrote:
> >
> > > Is it a good idea to reuse admin's JS datepicker widget in other apps,
> > > and if so,
min template? Do you
> not see your custom version? Or you don't see anything?
>
> Regards,
> Malcolm
>
>
>
> >
> The index.html is only for the index page, perhaps you meant to overide
base.html or base_site.html?
Alex
--
"I disapprove of what you
Just now {% ifequal %} doesn't support filter expressions as arguments. So
you must prepare values by {% with %} tag before using them in {% ifequal
%}.
On Mon, Mar 2, 2009 at 12:22 PM, eli wrote:
>
> Hi,
>
> I have a problem:
>
> Python:
> week = [1, 2, 3, 4, 5, 6, 7]
> # There are only two re
> registerResponse5 = UserCreationFormExtended(request.POST)
>
> if registerResponse1.is_valid() and registerResponse5.is_valid():
> userObject = registerResponse1.save(commit = False)
> userObject.email = registerResponse5 -> how can i access the
> email field value?
> > 5 super(MyForm, self).__init__(*args, **kw)
> >
> > What is the correct syntax for line 4? Is this even possible?
> >
> > Martin
> >
>
I reccomend you read this post:
http://www.b-list.org/weblog/2008/nov/09/dynamic-forms/
Alex
--
"I d
u'9']}>
>
> It seems that POST is ok, but cannot process it
>
> ¿any help?
> >
>
by default subscriping on a QueryDict object gives only the first item, so
you want request.POST.getlist('titulos').
Alex
--
"I disapprove of what you say, but I will defend to
he best way to handle something like this is with a
real caching system that is seperate from your python processes,
specifically memcache. Checkout the Django caching docs for how to use it
with Django.
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say i
7;mnem': 2}. To fix
this you want to seperate it into 2 filter calls
filter(mnem=1).filter(mnem=2). But that still probably doesn't do what you
want, since you can't have a field which has 2 values at once, therefore I'm
guessing you want to OR them together,
http://docs.djangopr
On Mon, Mar 2, 2009 at 2:56 PM, limas wrote:
>
> thank you Alex for your valuable reply.
> but i am still not able to find out the solution.
> i tried this:
> dataobj=DataValue.objects.filter(Q(file=file.id)|Q(mnem=1)|Q(mnem=2))
> but it is not working fine. it is returning ev
roject.com/browser/django/trunk/django/contrib/admin/media/css/base.css#L623
To lower that you'll probably need to write some of your own CSS to make it
play nice. FWIW it may just be that you have some really long strings being
displayed in certain places since I don't notice any issues on m
On Mon, Mar 2, 2009 at 3:23 PM, Peter Bailey wrote:
>
> Yeah, I have big objects in tables. Sigh, was hoping to avoid writing
> more css, but thought it might come down to that.
>
> Thanks Alex.
>
>
> On Mar 2, 3:09 pm, Alex Gaynor wrote:
> > On Mon, Mar 2,
gt; >
>
Yep, here's the code that makes it handle:
http://code.djangoproject.com/browser/django/trunk/django/db/models/fields/files.py#L195this
get's registered as a post_delete signal on any model that has a
filefield.
Alex
--
"I disapprove of what you say, but I will defend to the d
lve
> 179. for pattern in self.urlconf_module.urlpatterns:
> File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
> site-packages/django/core/urlresolvers.py" in _get_urlconf_module
> 198. self._urlconf_module = __import__
> (self.url
e
providing. The one thing I can say is it defintely can be done, look at
someone like webfaction, they have full mod_wsgi and Django support, and
even guarnteed RAM numbers for something like $10 a month.
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
sa
a response back
in some form. Using Django isn't hugely different from that, except you're
mostly using Django's provided stuff, it's WSGI interface, it's URL routing,
it's ORM, it's template, instead of using(for example) WebOb, routes, sql
alchemy, and Jinja.
Ale
it manually by
just putting 2 fields for each "field" one for each language.
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
"The people's good is the highest law."--Cicero
--~--~-~--~~
thon prompt. Any command prefixed with >>>
means it needs to be executed in a python shell. The reason you can't do
django-admin.py is because it's not on your PATH, someone more familiar with
windows could tell you how to alter that, but for now you can get to it by
providing
or reviews of Django
hosts, that being said they don't have anything on MochaHost.
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
"The people's good is the highest law."--Cicero
--~--~-~--~~-
or any help you can provide.
> kkaste
>
> On Mar 2, 5:24 pm, Alex Gaynor wrote:
> > On Mon, Mar 2, 2009 at 8:20 PM, kkaste wrote:
> >
> > > I followed the instructions for installing django. Apparently this was
> > > successful because I have a folder named
sily work a dollar to me.
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
"The people's good is the highest law."--Cicero
--~--~-~--~~~---~--~~
You received this message because you a
ew to the csv_view otherwise.
>
> Thanks in advance for any insight on this issue.
>
> ~G
>
> >
>
What you want to do is abstract the machinery that creates the queryset into
a seperate function, that way you can take the GET vars in both functions
and get a queryset from them. F
the Django
> documentation - using the search box helpfully provided on every page
> - for the word 'insensitive' provided the correct syntax as the top
> result.
> --
> DR.
> >
>
You probably want icontains actually, since your original query was
contains.
eriences ?
>
> Koen
>
> >
>
AFAIK the intention was always to eventually have a metaclass so it looked
more like model forms, but the usecase wasn't as strong, and no one who
wanted it ever wrote any code AFAIK
Alex
--
"I disapprove of what you say, but I will defend to t
It looks like your problem is probably on line 2. The {%
comment_form_target %} tag is trying to do a reverse url lookup.
However, there aren't any matches in your url conf.
Hopefully, you just forgot to set up a url for post_comment.
Unfortunately, what that usually means for me is that there is
blem yourself
during that testing.
Sorry I didn't have a quick answer, hope that helps.
Alex
On Mar 2, 5:41 pm, Roy wrote:
> *bump* anyone have any idea on this?
>
> On Mar 1, 9:17 pm, Roy wrote:
>
> > Hi group,
>
> > Say I have the ff in my base.html:
>
>
his an improper use of aggregation, or am I doing something wrong
> with my query?
> >
>
Before an aggregation is preformed all limits are removed, so you are seeing
expected behavior. I can't remember why this behavior exists though :/
Alex
--
"I disapprove of what you say,
d by John and Paul (not only by John
> and only by Paul). Who this could be done and who could this be done
> with a Q-object (in one query)?
>
> >
>
I suggest you start by taking a look at this section of the docs:
http://docs.djangoproject.com/en/dev/topics/db/queries/#spanning-mu
use aggregation and let the database find the
> maximum and minimum for me, but that doesn't work as Alex said.
>
> On Mar 3, 10:08 am, Alex Gaynor wrote:
> > On Tue, Mar 3, 2009 at 8:55 AM, Ross wrote:
> >
> > > I have started using aggregation, but it seems to ignor
,
> which,
> > > > unless you're using GROUP, is going to be 1. To do what you want,
> > > > you'd need a subselect, which (correct me if I'm wrong,) you'd have
> to
> > > > manually write in SQL. Like so:
> >
> > > > select sum(
; TIA,
> Brandon
> >
>
The not registered problem is probably because you have your user profile
application before django.contrib.auth in the installed apps list in your
settings, simply switch these around to fix that. The next thing you want
to do is make sure your new user admi
On Tue, Mar 3, 2009 at 12:54 PM, Alex Gaynor wrote:
>
>
> On Tue, Mar 3, 2009 at 12:41 PM, Brandon Taylor
> wrote:
>
>>
>> Hi everyone,
>>
>> Not sure what's up here, the same code works on another site.
>> Basically what I'm doing is
a project to do
> > something similar here:http://github.com/alex/django-filter/tree/master
>
> Thanks for the response, can you point me to the app you are referring
> to?
> >
>
It's linked in my message:
http://github.com/alex/django-filter/tree/master
Alex
--
&qu
Yaniv
> >
>
You haven't pasted your form class itself, so we can't well say what's not
correct. Please give us your form class so we have something to work with.
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltair
= forms.CharField(label=_("Password"),
> widget=forms.PasswordInput)
>password2 = forms.CharField(label=_("Confirm Password"),
> widget=forms.PasswordInput)
>tos = forms.BooleanField(widget=forms.CheckboxInput(),
> label=_(u
es someone have experience with ModelForm in GAE?
>
> Thanks, Yaniv
> >
>
You've now sent this message 3 times, either your mail program has a bug, or
please be patient :)
Alex
--
"I disapprove of what you say, but I will defend to the de
gt; >
>
You need to pass request.user.id to the templatetag, nothing automatically
has access to the current user or the current request.
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
"The people's good is the high
nd get the assertion error, it prints au.id, not the
> value of au.id
>
> what am i doing wrong?
>
> >
>
http://docs.djangoproject.com/en/dev/howto/custom-template-tags/#passing-template-variables-to-the-tag
Alex
--
"I disapprove of what you say, but I will defend to the deat
o this ?
>
>
>
> >
>
You can do it using the python kwarg syntax: Ship.objects.filter(**{field:
value}). You want to make sure you sanitze field so that the user can't
filter against something you don't want though.
Alex
--
"I disapprove of what you say, but I will defe
gt;
> "Use Javascript to clear the cache or some other trick" - Relying on
> JS being active is like relying on users.
>
> So, is this a feature waiting to be developed? Or is there a way to
> make it work right with the existing code?
>
>
>
> >
>
The most obviou
eference kinda thing?
>
> Cheers,
> Ishwor
>
The reason for making a copy is that by default the POST object isn't
mutable, that is you can't change the values of it's keys, so if you'd like
to change something in order to alter parts of it you'll need to ma
this, but if this works...
> >
>
But that requires actually pulling in all the records, not a big deal when
it's 100, but if it's more, and network latency is an issue you don't want
to do that. Plus I don't think negative slicing works in SQL.
Alex
--
"I disapprove o
never gets the request. I'm not
> running any firewall. Is there some other setting somewhere that allows the
> development server to serve up requests to external browsers?
>
>
> >
>
Try running the server at 0:8000 this tells it to serve requests to all hosts
ny queries, and 50+ would usually
five me pause however the question is always is it fast enough. And if
it is there is mo reason to worry. If it isn't you get to sit down and
do some profiling.
Alex
--~--~-~--~~~---~--~~
You received this message because y
ou do this you guys? I really
> need multiple keys...
>
> thx
>
> Arbi
> >
>
The ticket for composite ok support in django(373) has yet to be
resolved. The last work on it was done by David cramer and is I
believe available on github. That being said to my knowledge no p
lass B(models.Model):
>> amount = models.IntegerField()
>>
>>
>> class AForm(ModelForm):
>> class Meta:
>>model = A
>>
>> class BForm(ModelForm):
>> class Meta:
>>model = B
>>
>> Conflict of ids when forms printed:
e the email field is bizarrely small (it doesn't have
> the 'vTextField' class)...
> return super(MyModelAdmin, self).formfield_for_dbfield
> (db_field, **kwargs)
>
> Thanks a lot,
>
> Julien
> >
>
It's a suckasding issue. There is a ticke
On Mar 4, 2009, at 10:33 PM, Julien Phalip wrote:
>
> On Mar 5, 2:16 pm, Alex Gaynor wrote:
>> On 3/4/09, Julien Phalip wrote:
>>> Hi,
>>
>>> I can't find the exact cause of this, but it seems as though
>>> something
>>> ha
rofile)
> return HttpResponseRedirect('%sdone/' % request.path)
>
> else:
> myuser = User.objects.get(username = request.user)
> profile = Profile.objects.get(user=myuser)
> form = ChangePersonalInfo()
>
> context = Request
I run
> > manage.py test app1.TestCase1.test1 , it runs fine. For some reason
> > django is unable to find app tests. I have all the apps in
> > INSTALLED_APPS. What am I missing?
> >
> > Thanks,
> > saeb
> >
>
Does your application have a models.py file
b ON a.created_on <= b.created_on
> > WHERE a.object_id = 1
> > GROUP BY 1
> >
> > Which finds the sums for votes before the datetime of each vote.
> >
>
The real question is what question are you trying to answer with your query,
it may be possible with t
t; >
>
If you are using Django 1.0 or newer you can't use the latest release of
django-tagging, you need to use an SVN checkout.
Alex
--
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
"The people's good is the hig
Try this:
R.objects.values('type').aggregate(Count('type'))
On Fri, Mar 6, 2009 at 10:12 PM, kbs wrote:
>
> Hello,
>
> I got a model with a type field
>
>
> class R(mode):
>type = CharField(max_length=100)
>
>
> Here is what im trying to do using sql notation:
>
>
> SELECT typ,count(*)
This `dumpdata` command you can only serialize whole application not just
its models.
On Fri, Mar 6, 2009 at 11:17 PM, John M wrote:
>
> I tried using the command
>
> $ python manage.py dumpdata app.model.
>
> where app is the name of my application and model is one of it's
> models, I didn't a
401 - 500 of 1902 matches
Mail list logo