Introduction

It is possible to bulk import documentation or tags via a .CSV file - i.e. you can import multiple documents (see User Guide - Using the Annotate feature for more information) and/or tags (see User Guide - Working with tags) for multiple objects at the same time, rather than having to create them all manually in the UI. To do so:

Note that this method does not allow you to add Documents to a view.

Import process

Build the .CSV file

The bulk import process requires a .CSV file containing specific content and formatted in a specific way. A basic template is available here Document_Import_Template.csv, or it can be downloaded from the Import window in the Application management panel in the Admin Center:

The syntax of the .CSV file is as follows:

  • Each line in the file corresponds to one Document and/or Tag to be imported.
  • The line must contain information to identify the node/object to which the Document and/or Tag will be attached, and the title/content of the Document item and/or the content of the Tag.

The template file contains the following line:

"Object ID","Object Name","Object Full Name","Object Type","External","Document Title","Document Description","Tags"
Object ID, Object Name, Object Full Name, Object Type, External

These items identify the object/node that the Document and/or Tag will be associated with. To obtain this information, CAST suggests using the global search option to find the objects you want to add Documents and/or Tags to and then performing a Download to CSV (see User Guide - Export view options):

For example, the export contains five columns that match the required information:

Click to enlarge

I.e:

Object IDSource
Object NameSource Name
Object Full NameSource FullName
Object TypeSource Type 
ExternalWhether the object is classed as external or not. Please do not modify the value in this column - i.e. use the value that is given in the exported data.
Document Title

Enter the name of the Document , the description and tag you want to add - these will appear here:

Note that you can enter multiple tags for one object by using a comma separated list surrounded by quote marks, for example "My_Tag4,My_Tag10":

2233,Author,com.castsoftware.bookdemo.javabean.Author.Author,Java Constructor,2,My_Document4,My_Desc4,"My_Tag4,My_Tag10"

You are restricted from saving documents with tags having following prefix: Status-, CloudReady -, Containerization -, and StructuralFlaw -. 

Document Description
Tags

Example .CSV file

The .CSV example below adds a new unique document with an associated tag to four different objects:

"Object ID","Object Name","Object Full Name","Object Type","External","Document Title","Document Description","Tags"
2429,author,[D:\CAST\CONSOLE\CONSOLE_222_STANDALONE\data\deploy\MEUDON1\main_sources\JSP\ListTitles.jsp].author,Java Field,0,My_Document1,My_Desc1,My_Tag1
2945,Author,com.castsoftware.bookdemo.javabean.Author,Java Class,0,My_Document2,My_Desc2,My_Tag2
2734,Author,com.castsoftware.bookdemo.javabean.Author.Author,Java Method,0,My_Document3,My_Desc3,My_Tag3
2233,Author,com.castsoftware.bookdemo.javabean.Author.Author,Java Constructor,2,My_Document4,My_Desc4,My_Tag4

Upload the .CSV file

When the .CSV file with the required data has been created, the next step is to upload the file in CAST Imaging. To do so, use the following icon in the Applications panel in the Admin Center:

Then click Upload and choose the .CSV file:

The upload process begins:

When successful the following message is shown in the bottom right corner:

If the .CSV file is invalid (for example contains incorrect syntax), an error is displayed. In this situation you will need to check that your .CSV file meets the syntax requirements: