Fixed user pages to work with PGSQL.