Postgres Command Line Connect To Db Using Python To Extract