Importing Data by Using the Import Utility

You can run the Import utility in the following two ways:

Procedure

  1. You can import the data during databast initilization:
    To create the initial configuration file, take a configuration file generated by export, and add an [initdb] section to the top of it. You can also add any additional nodetypes, edgetypes, attribute descriptors, users, or indices to the initial configuration file. To specify the directory, which holds the files to be imported, add the line "dir = <directory>" at the beginning of the [import] section.

    Run initdb using the configuration file: ./tgdb -i -f -c import.conf

  2. You can import the data by using the import command in the administrative console:
    To import the entire database: import [dir=<directory>]
    For example, import dir=/opt/tgdb/import
    To import the selective nodetype: import selective (<nodetypename>[,<nodetypename>]+) [dir=<directory>]
    For example, import selective (houseMemberType) dir=/opt/tgdb/import
    Note: To import using the administrative console, the directory with the import files must include the configuration file generated by export or that you have generated manually.
    Note: Specifying a directory which holds the import files, is optional for both methods of importing. If the directory is left unspecified, import looks for the files in <tgdb_home>/bin