4 ms·
>But schemas are a YAGNI 99% of the time feature in those. What? I literally have only ever written one web app that didn't use multiple schemas, and that was
by asdasf 13y ago
>But schemas are a YAGNI 99% of the time feature in those.
What? I literally have only ever written one web app that didn't use multiple schemas, and that was a simple blog. I think you are confusing "I don't bother to use X" with "X isn't very useful".
- mattmanser 13y agoMost people don't bother with them, it's like juggling namespaces, mainly a complete waste of keystrokes. There's little to no chance of collisions but you have to use them constantly, which is annoying. Few benefits, lots of downsides.
- AlisdairO 13y agoI don't think it's just about collisions, in fairness. There's also the aspect of managing user permissions by schema, searching for tables, and so on. Obviously this only becomes super-useful in pretty sizeable projects, but I tend to consider using schemas a good habit to be in.
- asdasf 13y agoHave you ever tried using them before? You can set your search path, you don't need to type out schema.table. Your objects are already in a schema anyways, it isn't like you type out public.table all the time. What are these "lots of downsides" you leave unspecified? And how do they outweigh the benefits of grouping database objects together for both namespacing and permissions purposes?