Hi,
on all onstat -<something> commands output, at the first line on the right you have the current Shared Memory allocated size in Kb.
if you want more details, onstat -g mem and onstat -g seg are good candidates.
To have all the options of onstat, type onstat -- | more.
And if you are furious for coding SQL, explore the sysmaster database, but sincerely onstat is so practical and useful when you are in a rush.
Regards,
Eric