Synopsis
A SQL script is a set of SQL commands saved as a file. It can contain one or more SQL statements or PL/SQL blocks. You can use SQL Scripts to create, edit, view, run, and delete script files.
All modern RDMBS’ allow you to export an existing database into a single SQL Script file.
Import Considerations
- The name of the SQL Script file must be prefixed with the name of the database table it references. For instance, a SQL Script file named classic-model.sql must contain a database named classic. A script file should not contain more than one database description/definition.
- A database table may manage its uniqueness using compound (more than one) primary keys. As mentioned, this is discouraged and before exporting to a SQL Script file, steps should be taken to consolidate multiple keys into a single key.
Overview