adding two useful pg_scripts