简体   繁体   English

我应该添加新表以将新字段存储在zencart数据库中吗?

[英]should I add new table to store new field in zencart db?

should I add new table to store new field in zencart db? 我应该添加新表以将新字段存储在zencart数据库中吗? zencart original table zencart原装桌子

table : customers
customers_id | ...
1 | ...
2 | ...

now I need to add a new field for customer I create a new table 现在我需要为客户添加一个新字段,我创建一个新表

table : customers_extra
customers_id | is_blogger
1 | 0
2 | 1

or directly created in the customers table 或直接在客户表中创建

table: customers
customers_id | ... | is_blogger
1 | ... | 0
2 | ... | 1

which method should I use ? 我应该使用哪种方法? will add new table be worth to do ? 将添加新表值得吗? will it slow down the query speed? 会降低查询速度吗?

I would just add it on to the Customers table. 我只是将其添加到“客户”表中。 It's a lot less work that way. 这样可以减少很多工作。 And no, you won't experience a slowdown from adding a one character field to a table like this. 不,从这样向表中添加一个字符字段不会使您变慢。

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

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