News for hackers. Stuff that matters.
Re:Nanosecond timestamp collisions are common by EGreg on Friday July 21, 2023 @07:09AM (#36812400)
I dont know why people use relational databases other than they were first and “that’s the way it’s always been done”.

Why not use a graph database? O(1) lookups instead of O(N). Why need indices if you can just point to the data. Why use JOINs when map-reduce querying is far more flexible?

Re:Nanosecond timestamp collisions are common by tharkun__ on Friday July 21, 2023 @08:47AM (#36813150)
They were not first.

ISAM and VSAM come to mind. Yes it says "files" in there a lot but it got used like a database with programming interfaces like finding records in a database. If you will this method is more like NoSQL databases than a relational DB. The I in ISAM was a step towards not having to know the key (true "NoSQL"). Kind of like today's NoSQL databases all also give the ability to add indexes now.

https://en.m.wikipedia.org/wiki/ISAM

Re:Nanosecond timestamp collisions are common by dlisboa on Friday July 21, 2023 @10:14AM (#36814023)
I've been interested in learning more about them and how to best utilize them in my company. What graph database and query language would you recommend (regardless of stack)?
Re:Nanosecond timestamp collisions are common by EGreg on Friday July 21, 2023 @10:15AM (#36814033)
1. Memgraph 2. Neo4j

As for query language: definitely Cypher!

Re:Nanosecond timestamp collisions are common by madsbuch on Friday July 21, 2023 @11:23AM (#36814870)
How do you do constant time lookup an graph databases?

My intuition let's me know that you can not get below O(n log n) (Lower limit for comparison based ordering)

Re:Nanosecond timestamp collisions are common by eru on Sunday July 23, 2023 @04:46AM (#36833619)
> My intuition let's me know that you can not get below O(n log n) (Lower limit for comparison based ordering)

That intuition should point at O(log n), shouldn't it?

In any case, it totally depends how your data is stored and how/what you want to look up.

If you already have some kind of id of your node in the graph you want to look up, you can get O(1) lookup and still call it a graph database. If you have to traverse the graph, then it depends on the structure of the graph and where your entry point is, etc.

I'm rather skeptical of graph databases. Whatever they can do, you can do with a relation database and datalog. (Think of datalog as SQL plus recursion, perhaps.) See https://en.wikipedia.org/wiki/Datalog

Re:Nanosecond timestamp collisions are common by insanitybit on Friday July 21, 2023 @12:43PM (#36816093)
You aren't describing a property of a graph database. You're describing a property of some set of key value based systems.

The reason why you want indices is because some query patterns don't have a key to perform a look up on.

Re:Nanosecond timestamp collisions are common by eru on Saturday July 22, 2023 @10:54PM (#36832166)
You might want to read Codd's paper: https://www.seas.upenn.edu/~zives/03f/cis550/codd.pdf