Beginning of Chapter Next Chapter

10.16.2. Import XML

Use the Import XML window to import data from XML files into a database for the xTuple applications. If you try to open this window without first configuring the system for importing XML data, you will be given the opportunity to go directly to the Configure Import and Export window.

Import XML

When you open the Import XML window the table on the window is populated with a list of all XML files in the default XML directory for your computer (see Section 10.14.17, “Configure Import and Export”). To the far right of the screen, the following buttons are available:

Close

Close this window without doing any more work.

Add To List

Add another file to the list of files to be processed.

This file is not permanently added to the list; it will be removed when either it has been imported successfully or you close the window, whichever comes first.

Delete From List

Remove a file from the list of files to be processed.

This file is not permanently removed from the list; it will reappear after you try to import data from other files, click the Reset List button, or close and reopen this window. The only way to permanently remove a file from this list is to remove it from the default import directory. You can do this by importing the file successfully or by manually removing the file.

Reset List

Rescan the default import directory and refresh the contents of the on-screen table.

Files that have been imported successfully will be removed from the list, unless you selected the Do nothing after successful import option in Configure Import and Export. Any files you have added to the list with the Add To List button will be removed. Any files you have removed from the list with the Delete From List button will be put back.

Clear Status

The Status column in the on-screen table will be set to blank on all rows.

Import Selected

Import all of the files in the on-screen table that are currently selected. Each file is imported in its own transaction.

Read any error messages that appear carefully. Some of them explicitly state that the error will be ignored and that processing will continue after you acknowledge the message. These warn you of unexpected conditions in the imported data that do not appear as though they will cause problems.

Errors that are not marked as being ignored will cause the import of that one file to be rolled back but the other files will be processed until all selected files have been tried. This allows you to fix any problems with importing a particular XML file without having to retry all of the others as well.

Import All

Import all of the files in the on-screen table. This behaves exactly the same way as the Import Selected button except it processes all of the listed files, not just the selected ones.