简体   繁体   English

将用户数据存储在csv文件与数据库中

[英]storing user data in a csv file vs database

I am making a site where user can register and make posts using PHP. 我正在建立一个用户可以在其中注册并使用PHP发布帖子的网站。 Currently I have 2 tables in a db, and lots of csv files. 目前,我在db中有2个表,并且有很多csv文件。 Both of them together hold, username, password etc. and counters, posts, date etc respectively. 他们两个都分别持有用户名,密码等,以及计数器,帖子,日期等。

My Question is If it is a good idea to go with two storage systems. 我的问题是 ,使用两个存储系统是否是一个好主意。 Of course i can store all of it in a database. 当然,我可以将所有这些存储在数据库中。 My main concern is fast read & write capability. 我主要关心的是快速读写功能。

Also note that some data is required frequently, and some is required rarely, if i have to divide the data b/w csv & db, what can be better way? 另请注意,某些数据经常需要,而某些数据很少需要,如果我必须将数据黑白csv和db分开,还有什么更好的方法?

仅使用DB,而不是CSV。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM