The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.
You could always take a look at either gnu GDBM or Oracle-Berkeley DB to see how they solved the issue. Unless that's cheating, or you want to avoid any license issues.
Those DBM libraries simply work in a contiguous memory region and write the entire database back to disk when saved. That's why everyone avoided key-value-store (NoSQL is the new buzzword) databases for over a decade. When RAM became cheap and you build a server with terabyte of RAM... the old things became new again.
By the way... let's give credit to the inventing author... Ken Thompson[^] who wrote the first DBM implementation... sometime in the late 1970's. It's not even mentioned in his wikipedia bio... I wonder if anyone will remember that in 30 years.
Did Btrieve use separate files for its indexes versus its data or was it all in one file?
On systems with dual floppies, we sometimes implemented the index on one file one one floppy and the data on another. But those were dedicated turnkey systems on a 32KB machine with 720KB floppies (dual sided.)
That's actually a smart way to do it in any case - even if you had the space on one disk.
The reason is, as long as the floppy controller supported it, you could have both spindles working at once, and so you don't have as much I/O lag.
The same principle applies in modern databases and is why good database design will partition frequently accessed tables onto their own HD "spindles" - either physical spindles, or just logical like with an SSD - point is, you read from more than one drive at once.
When I was growin' up, I was the smartest kid I knew. Maybe that was just because I didn't know that many kids. All I know is now I feel the opposite.
Now, when I said that I can't "wrap my head around" using TypeScript, I'm basically saying that I don't know why I would want to use VB.NET instead of C#, when I'm already an expert at C#. Or worse, why I would write something in VB, transpile it into C#, and then evaluate it against the runtime.
"Never attribute to malice that which can be explained by stupidity."
- Hanlon's Razor
Last Visit: 20-Jan-20 12:08 Last Update: 20-Jan-20 12:08