There will be scenarios like the developer wants to export the DDL/Data of user objects like Table, View, Packages, Functions, Procedures, Trigger, etc. Using SQL developer you can export all the user-created objects in a particular schema. This will help you to keep backups, to move to another environment like development to UAT. It can be used for comparing two schemas.
Steps to follow
Step 1: Go to Tools -> Database Export
.
Step 2: Choose the environment/Connection that you want to export
Step 3: Opt file format. There will be options like insert, XLS, XLSX, etc. If you want it in a SQL format then you have to opt insert option.
Choose the destination directory location. After the export, the files will be saved in this location.
Step 4: Opt Save as type.
You can export the objects in a single file or as separated files. Also, you can export as different directories. Ie, it will create new directories named Table, View, Functions, etc and it will save the corresponding files to the directories
Step 5: Selecting Object types.
User can check the objects that want to export. By default, all the object types will be selected
Click Next then Finish.
Go to the destination directory and you can see all the exported files.