drkjzk3359 2011-02-21 11:41
浏览 17
已采纳

替代使用MySQL数据库发布“喜欢”?

I want to introduce a Facebook-like "likes" system, in that my members can click a like (or dislike) button and it rates the post up or down. A tally of the likes should be visible.

My first (and only) thought of implementing this is to create a new "likes" table in my MySQL database. But when I look back on websites such as Facebook and YouTube, who have billions of likes for all of their videos, it seems resource consuming to have a table that may contain that many entries.

The structure of the table would be

id, post, value, user

Are there any alternatives to using a MySQL table for "likes" ?

  • 写回答

1条回答 默认 最新

  • doufan9395 2011-02-21 11:43
    关注

    Are there any alternatives to using a MySQL table for "likes" ?

    There are, but what are you afraid of? A mySQL table is one of the most optimal forms to store lots of data in.

    You could look at noSQL databases and other forms of data storage, but my bet is you can easily stick with mySQL at the moment, and switch storage engines later if the project starts growing so massively that you need to go beyond relational databases.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 谁有desed数据集呀
  • ¥20 手写数字识别运行c仿真时,程序报错错误代码sim211-100
  • ¥15 关于#hadoop#的问题
  • ¥15 (标签-Python|关键词-socket)
  • ¥15 keil里为什么main.c定义的函数在it.c调用不了
  • ¥50 切换TabTip键盘的输入法
  • ¥15 可否在不同线程中调用封装数据库操作的类
  • ¥15 微带串馈天线阵列每个阵元宽度计算
  • ¥15 keil的map文件中Image component sizes各项意思
  • ¥20 求个正点原子stm32f407开发版的贪吃蛇游戏