this post was submitted on 06 Jul 2024
947 points (99.4% liked)
Programmer Humor
19453 readers
69 users here now
Welcome to Programmer Humor!
This is a place where you can post jokes, memes, humor, etc. related to programming!
For sharing awful code theres also Programming Horror.
Rules
- Keep content in english
- No advertisements
- Posts must be related to programming or programmer topics
founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
Forgive my ignorance. SQLite is a database software. Why would McAffee create lots of database files?
[Edit:] I’m not asking why a program needs to store data. I’m asking why that necessitates many files. One database file (or one per table) should be enough, right?
Many programs use SQLite internally and McAfee decided to store the database files in C:/Temp
No, these are sqlite temp files, not the database files. McAfee had no control over the temp files.
Sqlite is a great embedded database.
If you are storing lots and lots of information in a JSON file, CSV file, or coming up with your own serialisation... Chances are, sqlite is going to do it better.
I know loads of android apps use sqlite for storage. I've also managed to open quite a few programmes "proprietary" file format in sqlite.
A yes, the two genders of binary file formats: renamed sqlite file and renamed zip folder.
Don't forget renamed and compressed xml + zip
Aren't sqilte files themselves (like most other things) just fancy text files?
Nah, only actual string data is stored as text. Everything else is stored as binary: https://www.sqlite.org/fileformat.html#record_format
The file also isn't written sequentially, it's stored in blocks (pages), where sometimes later data can be inserted in the middle (e.g. when data was deleted).
I did say fancy.
Then I guess my laptop is just a fancy boat.
Haven't seen your laptop, but if it's anything like mine it's a very lousy boat.
Ahoy sailor
No: https://www.sqlite.org/fileformat.html
The program needs to store multiple temporary files (one per virus definition update, or scan results or whatever purpose).
It looks like they simply picked sqlite as a format because the data has a structured format and that way they leverage databases robustness, easiness to read and query the data.
The comment appears to be from 2006. Sqlite mightve had some limitations then that necessitated creating a new (temporary) database file as a subset of larger database for performance reasons or to allow multiple processes to read/write them and then consolidate data back into the single database.
Virus definitions?
Does sqlite create a file for every page in the table or what?
No, but developers are free to implement things in whatever crazy way they can dream up.
Nobody ever accused McTrellix of being efficient software 😆
Al sorts of applications would enjoy a database to log all sorts of stuff, store results, capture events, etc.
SQLite is great because it doesn't necessitate another infra dependency as it is stored to file