dougaojue8185 2015-05-11 20:25
浏览 59
已采纳

为什么wordpress序列化数据库中的数据?

Ok so im fairly new to wordpress programming and realized all their core data, and plugin data are always serialized. Doesn't this take away from the RELATIONAL aspect of a RDBMS? And it doesn't even save space because the strings are soooo long most of the time, and it's harder to scale/modify the data this way...

I don't understand why they decided to do this, and i haven't found any online references as to why they would do this.

  • 写回答

3条回答 默认 最新

  • duanqiao9541 2015-05-11 20:37
    关注

    Obviously, since I'm not a developer for Wordpress, I don't know their exact reason.

    But perhaps they came to the same conclusion as me:

    Sometimes, it's just not worth it. Sometimes, you just want to store some data. Sometimes, the database will never, ever do anything with that data other than send it back to the processing code. In cases like this, when the data will never relate to anything else in the database, why bother designing a relational database when a data-dump is all you need?

    Is it a good idea? Probably not, it's a lazy one that just works when you need it to with a minimum of fuss. However, if I ever catch you using MySQL to try and process data out of a serialised column, I will ban you from the internet.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(2条)

报告相同问题?

悬赏问题

  • ¥15 求chat4.0解答一道线性规划题,用lingo编程运行,第一问要求写出数学模型和lingo语言编程模型,第二问第三问解答就行,我的ddl要到了谁来求了
  • ¥15 Ubuntu在安装序列比对软件STAR时出现报错如何解决
  • ¥50 树莓派安卓APK系统签名
  • ¥15 maple软件,用solve求反函数出现rootof,怎么办?
  • ¥65 汇编语言除法溢出问题
  • ¥15 Visual Studio问题
  • ¥20 求一个html代码,有偿
  • ¥100 关于使用MATLAB中copularnd函数的问题
  • ¥20 在虚拟机的pycharm上
  • ¥15 jupyterthemes 设置完毕后没有效果