strzlee/JsonDB.class.php

Splitting the database into lines

xeoncross opened this issue · 1 comments

Loading the entire JSON object into memory isn't a good idea. Instead, I would use the file handle to search each line for the records needed. Each line in the file could be a JSON object.

In all truth though, I can't imagine any use for this instead of SQLite. SQLite is the most used database in the world and comes built into PHP. It's tiny, requires no installation, and has the full power of SQL behind it.

That's true. It's no alternative to SQLite or whatever, but I need this stuff sometimes to manipulate JSON files.