postresql, updated and cleaned