tkc, Is that the default created when adding db_index=True of is that something that I would do directly in postgres itself?
cheers L. On 17 June 2014 22:50, Tim Chase <django.us...@tim.thechases.com> wrote: > On 2014-06-17 11:04, Russell Keith-Magee wrote: >> On Tue, Jun 17, 2014 at 9:25 AM, Lachlan Musicman wrote: >> > Now reading about indexes I can't believe I've not used them >> > previously. >> >> Indicies are definitely your friend - *especially* on >> PostgreSQL. :-) > > I've found http://use-the-index-luke.com/ particularly useful in > learning to tune indexes for better performance. > >> In raw PostgreSQL compatible SQL, you're looking for: >> >> CREATE INDEX "appname_tablename_columnname" ON "appname_tablename" >> ("columnname"); >> >> (substituting the app name, table name and column name as >> appropriate). > > As you (the OP) will learn at the above URL, you can index on > multiple columns, so you can have > > CREATE INDEX "name_for_this_index" ON "appn ame_tablename" ( > "colname1", > "colname2", > --- > "colnameN" > ) > > for combined indexes which, if you regularly query those conditions > (particularly from first-to-last in terms of subsets), you'll see > notable performance improvements. > > -tkc > > > > -- > 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 group, send email to django-users@googlegroups.com. > Visit this group at http://groups.google.com/group/django-users. > To view this discussion on the web visit > https://groups.google.com/d/msgid/django-users/20140617075049.0556ba33%40bigbox.christie.dr. > For more options, visit https://groups.google.com/d/optout. -- The idea is that a beautiful image is frameable. Everything you need to see is there: It’s everything you want, and it’s very pleasing because there’s no extra information that you don’t get to see. Everything’s in a nice package for you. But sublime art is unframeable: It’s an image or idea that implies that there’s a bigger image or idea that you can’t see: You’re only getting to look at a fraction of it, and in that way it’s both beautiful and scary, because it’s reminding you that there’s more that you don’t have access to. It’s now sort of left the piece itself and it’s become your own invention, so it’s personal as well as being scary as well as being beautiful, which is what I really like about art like that. ----------------------------------------------------------------------------------------------------------- Adventure Time http://theholenearthecenteroftheworld.com/ -- 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 group, send email to django-users@googlegroups.com. Visit this group at http://groups.google.com/group/django-users. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAGBeqiPAPUDBYW4DTt48P7M0AxGrNC0dEdAZ3TydtYV9JG5hgw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.