Skip to content

Instantly share code, notes, and snippets.

@kmizumar
Created May 20, 2013 16:29
Show Gist options
  • Save kmizumar/5613407 to your computer and use it in GitHub Desktop.
Save kmizumar/5613407 to your computer and use it in GitHub Desktop.
select a.row_num as row, b.col_num as col, sum(a.value * b.value) as val
from a, b
where a.col_num = b.row_num
group by a.row_num, b.col_num
;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment