tags:

views:

674

answers:

4

I want to determine the size of my indexes, they are primary key indexes. This happens to be on mysql cluster but I don' think that is significant.

+1  A: 

Unused by me but perhaps MySQL Index Analyzer may be helpful.

Andrew Hare
A downvote without a comment is pointless. If I have said something wrong or if the link I have posted will not help please comment so that I can correct the problem.
Andrew Hare
I did not downvote it, but for some reason it does not work for calculating the size of primary key indexes on cluster
Brian G
A: 

On MyISAM, each index block is 4 KB page filled up to fill_factor with index records, each being key length + 4 bytes long.

Fill factor is normally 2/3

As for InnoDB, the table is always clustered on the PRIMARY KEY, there is no separate PRIMARY KEY index

Quassnoi
A: 

Using phpMyAdmin, when viewing the table structure there is a Details link at the bottom somewhere. Once you click on it it will show you the total size of the indexes you have on the table where it is marked Space Usage.

I don't think it shows you each index individually though.

Peter D
+1  A: 

I think this is what you're looking for.

show table status from [dbname]

http://dev.mysql.com/doc/refman/5.1/en/show-table-status.html

Josh Warner-Burke