OrientDB – Import Database
Whenever you want to import the database, you must use the JSON format exported file, which is generated by export command.
In this chapter you can learn how to import the database from the OrientDB command line.
The following statement is the basic syntax of the Import database command.
IMPORT DATABASE <input file>
Note − You can use this command only after connecting to a particular database.
Example
In this example, we will use the same database named ‘demo’ that we created in the previous chapter. You can use the following command to import the database to a file named ‘export-demo.gz’.
orientdb {db = demo}> IMPORT DATABASE ./export-demo.export.gz
If it is successfully executed, you will get the following output along with the successful notification.
Database import completed in 11612ms