ORASOLU TOOLBOX · MIGRATION

Migration Assessment

Practical Oracle SQL for reviewing database footprint, schemas, objects, invalid objects, installed options and dependencies before a migration.

ORASOLU TOOLBOX · MIGRATION

Understand the source before choosing the migration path

A migration assessment should establish what is in the source database, how large it is, which objects require attention and which dependencies or database features may affect the migration method. These queries provide a practical starting point for that assessment.

01 · DATABASE SIZE

Measure database storage

Review allocated datafile space to establish the source database footprint.

SELECT
  ROUND(SUM(bytes) / 1024 / 1024 / 1024, 2) AS allocated_gb,
  COUNT(*) AS datafiles
FROM dba_data_files;
02 · SCHEMAS

Review database schemas

Identify schemas and account status before planning users, ownership and migration scope.

SELECT
  username,
  account_status,
  default_tablespace,
  temporary_tablespace,
  created
FROM dba_users
ORDER BY username;
03 · OBJECTS

Profile database objects

Count objects by schema and type to understand application and metadata complexity.

SELECT
  owner,
  object_type,
  COUNT(*) AS object_count
FROM dba_objects
GROUP BY owner, object_type
ORDER BY owner, object_type;
04 · VALIDATION

Find invalid objects

Identify invalid database objects that should be understood before or after the move.

SELECT
  owner,
  object_type,
  object_name,
  status
FROM dba_objects
WHERE status <> 'VALID'
ORDER BY owner, object_type, object_name;
05 · OPTIONS

Review database options

Review enabled database options that may influence migration planning and target requirements.

SELECT
  parameter,
  value
FROM v$option
ORDER BY parameter;
06 · DEPENDENCIES

Inspect object dependencies

Review object relationships that can help identify migration ordering and validation requirements.

SELECT
  owner,
  name,
  type,
  referenced_owner,
  referenced_name,
  referenced_type
FROM dba_dependencies
ORDER BY owner, name, referenced_owner, referenced_name;

ORASOLU TOOLBOX · MIGRATION

Migration planning starts with a source inventory.

Database size, schemas, objects, invalid objects, enabled options and dependencies provide the baseline for deciding what needs to move and what needs additional validation.

Use these queries as an assessment starting point and correlate the results with the migration method, target architecture and application requirements.