Viewing statistics and histograms using sp_showoptstats

Adaptive Server includes sp_showoptstats, which functions like the optdiag standalone utility, extracting and showing, in an XML document, statistics and histograms for various types of data objects from system tables such as systabstats and sysstatistics. The syntax is:

sp_showoptstats [dbname[.owner[.[table_name] ] ] ], [.column],
	[option]

See sp_showoptstats in Adaptive Server Reference Manual: Procedures.