The key question

A short object name may point to different targets in different environments. A migration that only looks at visible SQL text can miss that indirect binding.

What to inventory

  • Inventory private and public synonyms including target and database link.
  • Resolve multi-step references to the actual object.
  • Document environment-specific names and privileges.

Design the target deliberately

Prefer explicit qualification or deliberately designed views where they make interfaces clearer. PostgreSQL search_path can influence name resolution, but it is not a general replacement for Oracle synonyms. Privileges and controlled search paths must be correct independently of naming conventions.

A concrete validation step

PostgreSQL · inspect current name resolution
SELECT current_schema(), current_schemas(true);

Evidence required before sign-off

  • Run queries with the intended application role.
  • Test name collisions across schemas.
  • Verify that every environment resolves to the intended business object.
  • Include dynamically generated SQL and remote targets.

Primary sources & further reading

These recommendations are engineering guidance. Specific options depend on source and target versions, privileges and operating model.