Archibus Web Central
Archibus Smart Client

Importing and Exporting Images (Data Transfer)

Some Archibus tables include image files (for example, eq.survey_photo_eq, bl.bl_photo, afm_redlines.html5_redlines, activity_log.doc4 ). This topic describes exporting and importing those files using Data Transfer.

Note: For general information about Data Transfer, see Data Transfer Overview.

Updating the record requires a changed field

When importing new images, the record that contains the image is not updated unless a field has been modified. If you are importing an image that has the same name as the original image file, the new image is not recognized as being a change. For this reason, in the examples given below, the Option 2 field is exported and modified to ensure that the record is updated. Any field can be used for this purpose, as long as you are not using the field, so that modifying it does not cause problems.

To transfer images out of Archibus

This procedure uses the example of transferring an image out of the Equipment (eq) table.

  1. Launch Smart Client
  2. Click the Views tab at the bottom of the Explorer pane.
  3. Open the “eq” table view:

  4. Use the View / Select command on the ribbon to display the fields you need . Make sure the image field is shown. For this example, that field is “eq.survey_photo_eq.”
  5. Ensure that the Option 2 field, or any field you are not using, is also shown in the view. See the above section - Updating the record requires a changed field.
  6. Click the View / Transfer command from the ribbon.

  7. The Data Transfer Wizard appears.

  8. Select: the Transfer Out option, and then click Continue.
  9. Select: “CSV – Comma Separated Value”
  10. Click Begin Transfer.

    The exported files will be in the following folder: "C:\Users\Public\Archibus\projects\users\afm\dt." Notice, there is a folder containing the image files, as well as a .csv file:

  1. Optionally, open the image folder (eq) to view the images:

To transfer images into Archibus

This example uses the “eq” table to demonstrate the process for transferring image files into Archibus. You may opt to transfer the data and images in via the Database Update Wizard, or by data transferring using Smart Client or Web Central. Both methods are described below.

To use data transfer to transfer the image files:

  1. Modify the Option 2 field (or whatever field you are using as the fields to modify) in the csv file that was transferred out in the above section Steps to transfer images out of Archibus.
  2. Using Windows Explorer, move the files that contain the data to be transferred in to the following folder: C:\Users\Public\Archibus\projects\users\public\dt\database-update\personalized-database

    Required files include

    Note: The version of the image file may need to be changed. If you are importing document files that do not currently exist in the database, then all versions of the images should be "1" (for example, survey_photo_eq^745361111494^1^ahu.jpg). If there is an existing document (photo) in the database, the version must match the latest version in the afm_docvers table. In the example just given, if after the import, the latest version number is 2, you would need to change the image file name from "survey_photo_eq^745361111494^1^ahu.jpg" to "survey_photo_eq^745361111494^2^ahu.jpg".

    The CSV file must be named the table name (for example, "eq.csv"), and the folder containing the images must be the table name (for example,. "eq").

  3. Using Smart Client or Web Central, data transfer in the eq.csv file:
    1. In Smart Client, click the View / Transfer command from the ribbon.

      The Data Transfer Wizard appears.

    2. Select the Transfer In option, and click Continue.
    3. Select Server File.

      The Server File field fills in with the name of the csv file you moved in step 2.

      Click Begin Transfer.

  4. Once the import is completed, verify that the image files are visible in Web Central.
  5. Remove the Option 2 value from the database.

To use the Database Update Wizard to transfer the files

The “Transfer In” action of the Database Update Wizard may also be used. to transfer in the image files.

  1. Modify the Option 2 field data in the csv file that was transferred out in the above section Steps to transfer images out of Archibus.
  2. Change the version of the image files to match the latest version in the afm_docvers table; that is, change "survey_photo_eq^745361111494^1^ahu.jpg" to "survey_photo_eq^745361111494^2^ahu.jpg".
  3. Open Web Central, and select the following task to open the Database Update Wizard:

    Archibus System Administration/ Add-In Manager / Run Database Update Wizard.

    The Database Update Wizard appears.

  4. Select “Transfer In” and then press the “Next” button.

  5. Under 'Named Tables,' select the check box for “Tables like,” and enter the table name in the box (for example, eq.)
  6. Click Next.
  7. Select the check box next to the table name and press the Start Import button:

  8. Verify that the image files are visible in Web Central.
  9. Remove the Option 2 value from the database.
Copyright © 1984-2020, Archibus, Inc. All rights reserved.