9.4 Examples
The following examples illustrate how to use the MIGRATEADVISOR
command.
Example 1
Generate the target properties file for Autonomous Database.
-- Set default directory
SQL> cd <directory>
-- Connect to target
SQL> set cloudconfig <config-file>
SQL> connect <autonomous-connect-string>
-- Generate the properties file
SQL> migrateadvisor properties -outfileprefix cloud
Example 2
Create the HTML Advisor report for a single schema using target properties.
-- Set default directory
SQL> cd <directory>
-- Connect to source
SQL> connect <database-connect-string>
-- Generate the report
SQL> migrateadvisor advise -schemas hr -outfileprefix hr -targettype adws -analysisprops <propertyFile>
Example 3
Create the HTML Advisor report for the full database using target properties.
-- Set default directory
SQL> cd <directory>
-- Connect to source
SQL> connect <database-connect-string>
-- Generate the report
SQL> migrateadvisor advise -outfileprefix fulldb -targettype adws -analysisprops <propertyFile>
Example 4
Create the JSON Advisor report excluding schemas.
-- Set default directory
SQL> cd <directory>
-- Connect to source
SQL> connect <database-connect-string>
-- Generate the report
SQL> migrateadvisor advise -excludeschemas hr,sales -outfileprefix xschemas -targettype adws -reportformat json
Example 5
Create the HTML Advisor report for multiple schemas including instance tests.
-- Set default directory
SQL> cd <directory>
-- Connect to source
SQL> connect <database-connect-string>
-- Generate the report
SQL> migrateadvisor advise -schemas hr,sales -full -outfileprefix fullmulti -targettype adws -analysisprops <propertyFile>
Example 6
Create HTML Advisor report for a single schema for migration to an Oracle database with target properties.
-- Set default directory
SQL> cd <directory>
-- Connect to target
SQL> connect <database-connect-string>
-- Generate the properties file
SQL> migrateadvisor -gettargetproperties -outfileprefix cloud
-- Connect to source
SQL> connect <database-connect-string>
-- Generate the report
SQL> migrateadvisor advise -schemas hr -outfileprefix ora -targettype adws -analysisprops <propertyFile>