some commented sql queries