Interesting idea, Andrew. I don't know how to do what you're asking for,
but I'd be interested to see it added too. I'd never heard of geometric
means, but I can already think of several areas where they might be
useful. Thanks for sharing the information on how they're calculated!
Matthew
This is probably not the most elegent solution, but here is something
that works in 3 SQL statements using user variables.
mysql select @gmean := 1, @ct := count(*) from g_mean;
mysql select @gmean := @gmean * test_val from g_mean;
mysql select power(@gmean, (1/@ct)) as Geo_Mean;
See details