title: "Group By" and other database algorithms?
body: <p>I've written some very basic tools for grouping, pivoting, unioning and subtotaling datasets sourced from non DB sources (eg: CSV, OLTP systems). The "group by" methods sit at the core of most of these.</p>
  
  <p>However i'm sure lot of work has been done in making efficient algorithms for grouping data... and i'm sure i'm not using them. And my Google-fu has completely failed to turn anything up.</p>
  
  <p>Are there any good online sources or books describing the better methods to create grouped data?</p>
  
  <p>Or should i just start looking at the MySQL source or something similar?</p>