Hello folks,
How to generate a temp table with frequency distribution counts between max and min values in:
select bincount(age) from personel where binSize = 5;
select freqdist(mileage) from cars where binNumber = 100;
or is there a way to write a stored procedure for the generic case where the size of the return temp table and number of select statements would be unknown? like
...
define min() max(), incr, etc etc
drop if exist temp table t, create temp table t,
...
insert into ... select count(q) from t where x <= q and q < x + 1*incr;
insert into ... select count(q) from t where x <= q + 1*incr and q < x + 2*incr;
insert into ... select count(q) ... (problem: repeat unknown number of times)
...
thanks
-- This message may have been cut off and the rest will only be shown to members. To become a member, click here --