See GRASS 5.0.x and PostgreSQL - First Steps for a general introduction. Also see the man pages for the GRASS database commands.