Ask php to save the data. thank you! My younger brother has a data query website. the expected data volume is very large. I first wanted to insert it into mysql for ease of query, but the actual data volume inserted every day may exceed MB, if you use mysql to estimate the cost increase, you do not know the efficiency. Therefore, I want to save data in the form of files. I have considered txt and xml, so it is a little difficult to read files. But I recently thought, can I save it as a file through serialization? (For my data, ask php to save the data. thank you!
My younger brother has a data query website. the expected data volume is very large. I first wanted to insert it into mysql for ease of query, but the actual data volume inserted every day may exceed MB, if you use mysql to estimate the cost increase, you do not know the efficiency.
Therefore, I want to save data in the form of files. I have considered txt and xml, so it is a little difficult to read files. But I recently thought, can I save it as a file through serialization? (Because my data is essentially an array of data.) if all data is serialized and directly deserialized during reading, how efficient should it be?
I want to hear from experts. thank you !!
------ Solution --------------------
Should the number of queries read more than the number of writes? No need to use files in the database, IO will consume the machine's
------ Solution --------------------
Only data that is not frequently changed in the cache is meaningful. Otherwise, the overhead of checking whether the data is updated cannot be ignored.
If your data is only some array data, the most efficient is to save the var_export result to the program file.
You only need to include