是否有多个列包含空值的数据库表的性能问题? [英] Is there Performance Issue for Database Table with multiple Columns containing null value?

查看:114
本文介绍了是否有多个列包含空值的数据库表的性能问题?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如果我设计一个包含10列的数据库表,varchar(1000)但不是所有列都有值会有什么影响?



此表将用于作为我的几个表的审计表。

What would be the impact if i design a database table with 10 columns all varchar(1000) but not all columns will have values?

This table will serve as my audittable for several tables.

推荐答案

请参阅我对该问题的评论。这取决于你想要比较这个决定。无论如何,我无法想象比实际使用这些空值时更有效的解决方案。你几乎不会出错。



-SA
Please see my comment to the question. It depends what you want to compare this decision with. Anyway, I cannot imagine more efficient solution than when you actually using those null values. You hardly can go wrong with them.

—SA


没有性能问题使用VARCHAR。使用的空间仅用于存储在列中的数据长度而不是整个1000.



您还可以阅读其他性能提示在其中 [ ^ ]
there is no performance issue in using VARCHAR. the space utilized is only for the length of the data stored in the column and not whole 1000.

you can also read other performance tips here[^]


这篇关于是否有多个列包含空值的数据库表的性能问题?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆