Console - CONNECT
Opens a database.
Syntax
CONNECT <database-url> <user> <password>
<database-url>
Defines the URL of the database you want to connect to. It uses the format<mode>:<path>
<mode>
Defines the mode you want to use in connecting to the database. It can beplocal
orremote
.<path>
Defines the path to the database.
<user>
Defines the user you want to connect to the database with.<password>
Defines the password needed to connect to the database, with the defined user.
Examples:
Connect to a local database as the user
admin
, loading it directly into the console:orientdb>
CONNECT plocal:../databases/GratefulDeadConcerts admin my_admin_password
Connecting to database [plocal:../databases/GratefulDeadConcerts]...OKConnect to a remote database:
orientdb>
CONNECT remote:192.168.1.1/GratefulDeadConcerts admin my_admin_password
Connecting to database [remote:192.168.1.1/GratefulDeadConcerts]...OK
For more information on other commands, see Console Commands.