select context_id from acs_objects where object_type = 'organization' gives the right package_id for organizations.
for project-manager (thanks to daveb):
SELECT
package_id
FROM
cr_folders
WHERE
description = 'Project Repository'
LIMIT 1
Gets the right ID.
select context_id from acs_objects where object_type = 'logger_project' limit 1 also seems to work.
Any preference on how to get the package_id for project manager?