Reputation: 33534
Here is a solution how calculate table size, but what about column? Is there apporoach to calculate data which stored only for 1 column of table?
Note
The question is about data size, not data type size.
Upvotes: 10
Views: 4478
Reputation: 1646
You can use below query that will return data size in bytes:
SELECT sum(char_length(comment)) FROM tbl_comments
Upvotes: 7
Reputation: 31
You can check in the storage requirements in the reference manual, and you can calculate your column size.
If you don't want to read too much, you can find some page, where is a collection about sizes and an online calculator: calculator
Upvotes: 2