Sample Header Ad - 728x90

Is it possible to expose the max depth of the B-Tree behind a rowstore index or a way to see how many nodes were traversed for a particular query?

4 votes
2 answers
590 views
I'm personally interested in data structures and with knowing that rowstore indexes are stored with a B-Tree behind them, I'm always curious in trying to visualize what those B-Trees look like for a given table/index. Is there a way to correlate or expose the number of nodes in a B-Tree for a given rowstore index via the execution plan, statistics, operator properties, index / table properties etc? Furthermore can I do the same to determine the number of nodes traversed for a particular query? Bonus points if there's a way to determine the number of leaf nodes in the B-Tree too.
Asked by J.D. (40903 rep)
Jul 10, 2020, 01:04 AM
Last activity: Oct 2, 2022, 04:29 PM