Skip to content

Tag: sql

SQL How do I query a many-to-many relationship

How do I select posts that contain a specific tag if there is a many-to-many relationship between posts and tags? The problem I am having is that because of the where tag.name = ‘xxx’, only that tag is selected. I want to select all posts that have the tag specified, together with all of their tag…

Aggregating save()s in Django?

I’m using Django with an sqlite backend, and write performance is a problem. I may graduate to a “proper” db at some stage, but for the moment I’m stuck with sqlite. I think that my write performance problems are probably related to the fact that I’m creating a large number of ro…