Sophie wrote:

> Is there a reason the cateogry \$$\mathbf{Set}\$$ is the "chosen" category when we define databases?

The main reason is a practical one: we are often interested in databases that consist of a bunch of sets and functions between these sets. But we are often interested in other kinds, too - and that's the topic of [Lecture 40](https://forum.azimuthproject.org/discussion/2223/lecture-40-chapter-3-relations/p1)!

> Will we get interesting properties that we wouldn't get if we just defined a database to be functor from \$$\mathbf{Free}(G)\$$ to any category?

Yes, lots. The category \$$\textbf{Set}\$$ has a lot of nice properties, many of which can be summed up in the word "topos". The category of functors \$$F : \mathcal{C} \to \textbf{Set}\$$ inherits many of these nice properties: it too is a topos!

But I haven't said what the _category_ of functors \$$F : \mathcal{C} \to \textbf{Set}\$$ is, yet. Its objects are functors \$$F : \mathcal{C} \to \textbf{Set}\$$ and its morphisms are "natural transformations". These are discussed in Section 3.3.4 of the book, so you may want to read about them and see how they help us think about databases... but we'll get to them soon.

I also haven't said what a "topos" is; you can read about those starting in Section 7.2.

> Or to a specific category like \$$\mathbf{Grp}\$$?

Of course practically speaking we are unlikely to have a database where there's a _group_ of employees! "Hey, I just multiplied Bob and Mary and got Frank!"

But functors \$$F : \mathcal{C} \to \mathbf{Grp}\$$ are important in math: we call these "group objects in the topos of functors \$$F : \mathcal{C} \to \textbf{Set}\$$", and they behave a lot like groups.