SQLite Forum

SQLite3 Extension
Login
.. much better indeed. thanks for the remark.

 
with datas(criteria, qty) as( values ('a', 1) ,('a', 2) , ('a', 3), ('a', 4) ,('a', 5), ('b',1), ('b',3) )

select criteria, sqrt( (sum(qty * qty) -  sum(qty) * avg(qty)) /count( * )) as stddev from datas group by criteria