To centrally store and manage product information, a master catalog is created in WebSphere Product Center. The following sections describe each step that is performed to collect the data from various sources and to assemble the information into organized catalog structures.
- Overview of the Import Console
- Obtaining a data source
- Define items that are needed to create an import feed
- Setting up an import feed
- Load incoming file into WebSphere Product Center
An import is a feed that inputs data from an external source into WebSphere Product Center. An import is first configured manually and can then be run on a scheduled or on-demand basis. WebSphere Product Center allows the import of multiple types of data (items, binary files, category trees, categorization mappings, etc.) from multiple sources to accomplish multiple purposes (update, replace, delete).
The Import Console is the tool that is used to create catalogs from various sources of data. The import console acts as the switchboard for importing all data into WebSphere Product Center. From here you can view, modify and create data that is being fed into WebSphere Product Center.
To create an import, user needs to define and perform the numerous data and file feeds into WebSphere Product Center. The import console presents a list of feeds that have been created.
To access the import console, use the menu path Collaboration Manager > Imports > Import Console.
Figure 7.1 - Import console
Customizing the console view
The console can be customized to sort or hide columns. The settings are saved to the user’s profile. To customize the view of the Catalog Console, do the following.
1. In the top right corner of the Catalog console, click the configure button
. The Configure table appears in a popup window.
2. To sort a column, make a selection in the Sort Column. Only one selection can be made.
3. To hide a field, make a selection in the Hide column. Multiple selections can be made.
4. In the "Other Options" table, set the sorting order to display in ascending or descending order and set the number of rows to display per page.
5. To save the customized settings, click Save. The Catalog Console appears with the new customized settings.
Sorting a list of imports
- The imports in the Import Console can be sorted by the "Type" of import or by the "Name" of the import. Click the "Name" or "Type" column heading name to sort.
Console Columns
The following table lists each of the columns of the Import Console.
Type
Icon indicating the type of import, refer to the previous section "Import Console Icons" for a list of import types
Name
The name of the import
Retrieved Files
A drop-down selection of source files that have been retrieved into the WebSphere Product Center document store
Retrieve
Execute the manual loading of the data source into WebSphere Product Center
Load
Uploads the data source into a specified catalog
Semantics
Indicates if the import is of type Update, Replace or Delete.
Source
The name of the source file used
File Spec/Import Script
Name of the file spec or import script used
Map
Click on the icon to view or edit the file to catalog mapping
Ctlg/Cat Tree
The catalog and catalog tree used for the import
ACG
The ACG used for the import
Before an import is created in the Import Console, there are several steps to perform in preparation of an import. This section describes the following import preparation tasks before an import is created and scheduled:
- Obtain data source
- Make data available
- Review data file
- Create required objects to setup an import
Before data can be imported into WebSphere Product Center, the source files must be situated in an accessible directory or FTP site. Review the data file to ensure the most accurate product information and that the format uses one of the following data sources available for import into WebSphere Product Center:
- Character Delimited
- Tab Delimited
- Comma Separated Values (CSV)
- Fixed Width
- XML
Note: The source file must conform to one of the formats mentioned in the list above before continuing with the next step.
Check that the source data file is available for access into WebSphere Product Center. If the files are to be uploaded through FTP, make sure that the proper permissions are applied to the FTP site. Contact the appropriate team members, as needed.
Analyze the source data file and make note on the file structure, fields, and associated attributes. This information is required to build the File Spec in the next step.
There are several objects that are required to be present prior to setting up an import. Many of these objects can be created during the setup of an import, but it may be easier to have these tasks completed beforehand. The following objects are the minimum requirements to set up an import:
File spec A file spec is required in order to configure an import. Please refer to the Data Model Manager section on creating a file spec. Primary spec A Primary Spec is required in order to configure the format of the WebSphere Product Center catalog structure. This may include specs for Hierarchies. Refer to the Data Model Manager section on creating a primary spec. Spec mapping In order to properly route data to the correct catalogs, the file spec needs to be mapped to the right catalog/hierarchies. Please refer to the Data Model Manager section on mapping specs. Create catalog using primary spec Once the file, catalog, and other associated objects have been created and mapped, the next step is to create the catalog. Please refer to the section on Product Manager for more information on creating a catalog.
After setting up the items for an import as described in the section "Import preparation" , define how the external file information is going to be populated into WebSphere Product Center catalogs. The definition of an import feed is done by creating a new import.
Figure 7.2 - New Import wizard
Create a new import
Use the menu path Collaboration Manager> Imports > New Import or click New in the Import Console. The New Import wizard appears. Complete each step of the Create Import wizard to create an import.
1. Import Name
Enter a name for the import and click the Next button.
An import name must be provided to distinguish from other names. Duplicates are not allowed. The feed name chosen should be comprehensive.
For example, the names "Item Attributes from Mainframe" or "Images for Catalog X" are good names.
2. Select Access Control Group
Choose Access Control Group from the Select Access Control Group drop-down menu. If Access Control Group does not exist, create one by clicking on NEWbutton.
3. Select Data Import Type
Choose a data import type from the drop-down menu and click the Select button. The following values are available for selection:
Binary Feed Feed of binary files for each item in a catalog (i.e. images, docs and PDFs). Hierarchy feed Hierarchy feed includes a hierarchy that is designed to organize all of the items within the catalog for easy browsing. Item feed Item feed contains the essential descriptive information that describes each catalog item to be found within the product catalog. Item to category map feed Item to category map feed maps items that already exist in a catalog to a hierarchy that will be uploaded as part of the incoming data. This feed can also be used to upload a file that contains new items and the appropriate categorization information directly into a new catalog. The hierarchy will be updated whenever any new category is added. 4. Select Data Import Semantics
Choose an import feed semantic and click the Select button.
The import feed semantics specifies how the incoming file will affect the items already found in the destination catalog.
Update Updates the item found in the catalog with the item that is specified in the incoming file and adds items to the catalog that only exists in the incoming file. Replace Replaces the content of the current catalog with the content of the incoming file. Delete Deletes from the catalog any items specified in the incoming file. 5. Select Data Source
Choose a data source name and click the Select button. A data source defines which data source is to be imported into WebSphere Product Center.
In this step, a user can modify or create a new data source. To create a new data source, click "New" and to edit a data source, click the Edit button.
The steps of creating a new data source include specifying a name for the data source and selecting a data source type. The data source name should be as descriptive as possible. Data source types include the following options:
- Have WebSphere Product Center retrieve via FTP
- Take from Document Store (including FTP)
- Upload via Web Browser
6. Select Character Set
The next step is to select the encoding of the incoming file from the "Select charset" drop-down menu. Select the character set that matches the one used in the incoming file. This is particularly important when incoming files contain characters outside the 26 letters of the alphabet and the 10 digits. The system default is "Cp1252: Windows Latin-1".
Note: Failure to select the appropriate character set may result in problems during import.
7. Select File specification
The file specification defines the attributes and format of the incoming file. Either choose an existing file specification from the drop-down menu or click New to create a new file specification.
8. Select Catalog
The catalog defines where the data will be imported into WebSphere Product Center. Either select an existing catalog or click New to create a new catalog.
9. Select File to Catalog Mapping
Either select an existing mapping or click New to create a new mapping. To create a new mapping (or modify an existing mapping) use the drop-down selection field to match each field in the file specification (left column) to match a field in the catalog (right column). For advanced manipulations (field concatenation, string manipulations, etc.) click on the Expression Editor button.
10. Select a Catalog Import Script
A simple catalog import script is always generated by default. Either select the default generated script or click New to create a new import script.
11. Select Approving Authority
The final step in creating an import feed is to select an approving authority. This optional step allows the selection of a user who is given the responsibility to review the import job and approve it before it is generated. Select which user should be notified when then feed is initiated.
12. Return to Import Console
At this point, the import feed is configured and the last step is to run the import job to populate the catalog where it can be managed within WebSphere Product Center.
Once an import has been defined, the import can be manually scheduled or set to run on demand. Before running an import, the external data source file must first be obtained.
Load file into Document store
On the Import Console, there are two GO buttons for each import feed, one in the Retrieve column and the other in the Load column.
To retrieve the external incoming file, click on the GO button in the Retrieve column of the appropriate import feed. The retrieved column will show "No files for feed." When the files are fetched, a selection of files appears in a drop-down menu.
Once the file has been fetched, it is placed into the Document Store. The Document Store is a repository for all files and data that are moved into or out of WebSphere Product Center. This provides the user with an opportunity to preview all files before they are actually uploaded into WebSphere Product Center.
Start import
The second of the two GO buttons on the Import Console will upload the fetched file from the document store into the specified catalog. From the Load column, click the GO Button.
An alert can be configured to notify, via email or through the Alert module of the Home Page that the load has completed. If an approving authority has been assigned, the feed can be approved or rejected through the user's Home Page Alert module inter. The product information can then be managed through the Product Manager Module.
Modifying an import
To modify an import, it is best to delete the old import and create a new one. For example, there is no method of selecting a new file spec. To use a different file spec, create a new import and select the appropriate file spec.
Deleting an import
A feed can be deleted by clicking on the delete button in the first column of every feed.
Note: Deleting a feed is not reversible. A dialog box will appear to verify the deletion of an import feed.
Binary files must be compressed before they are imported into WebSphere Product Center. For example, to import a group of images, a file of *.zip is created in a source directory. Once the compressed file is retrieved, it is stored into WebSphere Product Center's Document Store and then uncompressed into the docstore's directory /public_html/ctg_files. Binary files can include such files as jpg, gif, or pdf.
Figure 7. 4 - Uploading binary feeds
Create a binary import
The following steps create an import feed for binary files.
Use the menu path, Collaboration Manager > Imports > Import Console, the Import Console appears. Click New to access the "New Import" wizard . Complete each step of the wizard.
1. Import Name – Enter a name for the binary feed
2. Select Access Control Group – Select an access control group used for the feed.
3. Select import type – Select "Binary feed"
4. Select import semantics – Select "Update"
5. Select data source – Select a data source for the binary feed or create a new one
Keep path from zip archive Y or N
Always select No. All image files are stored in the "public_html/ctg_files", in the Document Store. If you preserve the path of the archive, the images will extract into the wrong directory.
6. Enter docstore path
Leave empty and click Next. The docstore path is assumed and there is not need to enter a path. When the application unzips the file, it will place all images into the ctg_files directory.
7. Select action on file name and path
Accept the default Neither - This option is sued the case of the images from downstream systems. In this case there is no problem with the images files being either uppercase/lowercase.
8. Select Approving Authority – Select a user to approve the import, if necessary.
This completes the creation of the Import Feed. The next step is to upload the compressed file into WebSphere Product Center.
Upload Compressed File
After the binary import feed is defined, the next step is to retrieve the compressed file into WebSphere Product Center. The feed should show "No files for feed" in the "Retrieve Files" column.
1. From the Import Console, locate the newly created feed and click Go! from the Retrieve column.
2. Click Browse, select the compressed file, and then click Upload. The path to the zip file appears in the "File" field.
3. Return to the Import Console or to view the file in the Document Store, select the Document Store from Collaboration Manager menu.
All uploaded files are stored in a sub-directory of the organization's "feed_files" directory, which is named after the name of the import feed.
Once the compressed file is uploaded to the Document Store, it is uncompressed.
Uncompress Binary Files
1. From the import console, click Go! from the "Load" column. WebSphere Product Center, unzips the images into the ctg_files directory.
2. To check the status of the process load, click the "check the status of the update" hyperlink.
When the load is completed, the Schedule Status Information shows the status "Completed Running". Click the document store hyperlink to view all of the uncompressed binary files.
An existing import table can be imported from an external data source into WebSphere Product Center. Creating an import for a lookup table is similar to creating any other import using the "New Import" wizard.
Create a lookup table import
From the Import Console, click New. The "New Import" wizard appears.
1. Select a unique feed name.
2. Select an Access Control Group.
3. Select the data type "item feed".
4. Select the relevant feed semantics, data source, and file specification
5. From the "Select Catalog" field, select the lookup table to be imported
6. Define the file to lookup table mapping
7. Select the import script. Create a new import script if necessary.
8. Select the approving authority, if necessary.
9. Save the new import feed.
10. Run the import