Using working copies for safe development in Oracle APEX helps developers isolate changes, test new features, and avoid disrupting production applications. A working copy is essentially a separate instance or version of your application where you can freely experiment without affecting live users. This approach promotes safer development cycles by enabling developers to develop, debug, and validate enhancements before merging changes back into the main application. In this blog, we explore how to create and manage working copies in Oracle APEX for secure, efficient development.How to Use Working Copies in Oracle APEX
-
Export Your Current Application
Begin by exporting the current stable version of your application as a SQL script using the APEX export feature or the APEXExport command-line tool. -
Create a New Workspace or Schema for Development
Set up a dedicated workspace or schema that mimics the production environment. This isolated environment serves as your sandbox for development. -
Import the Exported Application as a Working Copy
Use the import feature in Oracle APEX to load the exported SQL file into your development workspace, creating a working copy of the app. -
Develop and Test Independently
Make your changes, test new features, and fix bugs within this working copy without impacting production. -
Version Control Your Working Copy
Export the working copy periodically and commit changes to version control to track your development progress. Merge Changes Back to Production
Once development and testing are complete, export the updated working copy and import it into the production workspace, or apply necessary updates carefully.
Best Practices for Working Copies
-
Maintain separate environments for development, testing, and production to prevent accidental data or logic corruption.
-
Keep your working copies in sync with production by regularly exporting and importing updates.
-
Use version control to manage working copy exports and document changes.
-
Automate backups of both production and working copies before significant changes.
Communicate clearly with your team about which version is under development to avoid conflicts.
Instead of modifying the production app directly:
Go to Utilities > Application Copy.
Create a working copy.
Test changes in the copy before merging them into the main app.
Key Backup Best Practices
Export Application & Workspace Regularly
Backup the Database (Data Pump & RMAN)
Store Backups in Multiple Secure Locations
Use Flashback & Undo for Quick Recovery
Test Restores Periodically
Leverage Version Control (Git, SVN)
Use Working Copies for Development Safety
In Oracle APEX, working copies allow developers to safely test and experiment with changes before applying them to the live application. Using working copies properly can help prevent issues in production, facilitate collaboration, and improve overall development workflows.
Understand When to Use a Working Copy
Use a Working Copy When:
Making significant UI/logic changes.
Refactoring page structures, processes, or PL/SQL code.
Testing new features before deployment.
Preparing an application for an APEX upgrade.
Collaborating with a team while keeping a stable version.
When performing upgrades or migrations.
When making major changes to an application.
Do NOT Use a Working Copy When:
Performing minor text or style changes (use Live Edit or Developer Toolbar instead).
Debugging small issues in development mode.
Managing multiple environments (use version control or multiple APEX instances instead).
Creating a Working Copy of an Application
Go to App Builder and find the application you want to duplicate.
Click on Utilities > Application Copy.
Choose Copy Application and enter a new name (e.g., "MyApp_Test").
Select the components you want to include:
Pages
Application Definition (Pages, Shared Components)
Authentication & Authorization
Shared Components
Data Model
Click Create Application.
This will create a separate copy of the application that you can modify without affecting the original.
Merge Changes from a Working Copy
Once you're satisfied with the changes in the working copy:
Manually track the changes made in the copy.
Apply them to the original application by updating pages, components, or SQL scripts.
Oracle APEX Documentation Links
Conclusion
Using working copies in Oracle APEX enables safe, structured development by separating experimental changes from production environments. This practice minimizes risk, facilitates testing, and improves collaboration among developers. By exporting, importing, and managing application versions carefully, and leveraging multiple workspaces, you create a development process that is both robust and flexible—ensuring your applications evolve smoothly without compromising reliability.