3 ms·
The problem is this exposes you directly to storage mechanism internals. A good example of this is Redis. Redis is exactly what you described. It's just data s
by winrid 3y ago
The problem is this exposes you directly to storage mechanism internals.
A good example of this is Redis. Redis is exactly what you described. It's just data structures as a service.
For Redis - this works. It's its purpose. It's a tool. Same with KV stores. Again, you are working directly with the storage mechanism.
However, now you're limited to that implementation detail. With SQL, or a traditional DB, your SELECT x by y could be served by a hashmap today, and maybe a btree tomorrow, and you don't need to change your app.
Whether this makes sense for you depends entirely on your application. For loops in Python are okay for some apps. It won't work when you have a billion records.