Manage catalog objects using the Data Load utility

We can use the Data Load utility to load the catalog data to Watson Content Hub.


Before beginning


Task info

To use the Data Load utility to upload catalog data to Watson Content Hub, we must generate the catalog entry and catalog group data into CSV files, configure the Data Load utility for our CSV files, then run the utility.


Procedure

  1. Generate your catentry.csv file. For a sample file, see the following:

    1. Create a file named catentry.csv.

    2. Populate your file by referencing the following table:

      Column Required Field name Field type Description
      1 Yes PartNumber Varchar (64) A reference number to identify the part number of the catalog entry.
      2 Yes Thumbnail Varchar (254) The thumbnail image path of this catalog entry.
      3 Yes FullImage Varchar (254) The full image path of this catalog entry.
      4 No Angle1_FullImage Varchar (254) The full image for an alternate image of your product.
      5 No Angle1_Thumbnail Varchar (254) The thumbnail image for an alternate image of your product.
      6 No Angle2_FullImage Varchar (254) The full image for an alternate image of your product.
      7 No Angle2_Thumbnail Varchar (254) The thumbnail image for an alternate image of your product.
      8 No Angle3_FullImage Varchar (254) The full image for an alternate image of your product.
      9 No Angle3_Thumbnail Varchar (254) The thumbnail image for an alternate image of your product.
      10 No Angle4_FullImage Varchar (254) The full image for an alternate image of your product.
      11 No Angle4_Thumbnail Varchar (254) The thumbnail image for an alternate image of your product.
      12 No Angle5_FullImage Varchar (254) The full image for an alternate image of your product.
      13 No Angle5_Thumbnail Varchar (254) The thumbnail image for an alternate image of your product.

    3. Save and close the file.

  2. Generate your catgroup.csv file. For a sample file, see the following:

    1. Create a file named catgroup.csv.

    2. Populate the file by referencing the following table.

      Column Required Field name Field type Description
      1 Yes GroupIdentifier Varchar (64) An external identifier for our group.
      2 Yes Thumbnail Varchar (254) The thumbnail image path of this catalog group.
      3 Yes FullImage Varchar (254) The full image path of this catalog group.

    3. Save and close the file.

  3. Run the Data Load utility to load the catalog entry and catalog group data.

    1. Go to the following directory:

    2. Run the following command to load the catalog entry data:

      • dataload ..\samples\DataLoad\Catalog\WatsonContentHub\wc-dataload-catalogentry-wch-creationAndAssociation.xml

      • ./dataload.sh ../samples/DataLoad/Catalog/WatsonContentHub/wc-dataload-catalogentry-wch-creationAndAssociation.xml

    3. Verify that your data catalog entry correctly loaded by logging in to the Catalog tools in Management Center and checking to see if the catalog entry data is present.

    4. Run the following command to load the catalog group data:

      • dataload ..\samples\DataLoad\Catalog\WatsonContentHub\wc-dataload-cataloggroup-wch-creationAndAssociation.xml

      • ./dataload.sh ../samples/DataLoad/Catalog/WatsonContentHub/wc-dataload-cataloggroup-wch-creationAndAssociation.xml

    5. Verify that your data catalog entry correctly loaded by logging in to the Catalog tools in Management Center and checking to see if the catalog group data is present.

Previous topic: Adding content or assets to Watson Content Hub using wchtools