In this tutorial you will learn, how to configure fields of the product master table. The configured table can look, for example, like this
Let’s say you have following data file and need to create a table suitable for storage of such data.
Review the current product master table
Navigate to
The Products master table exists out of the box, but not all the field labels are not matching the labels in the ProductMaster CSV file. When you hover over the column label, a tooltip will display the name of the column in the back-end database.
From this table layout we can see that we have a standard set of defined columns: Product ID, Label, Product Unit, Currency, Last Update and Pricing Logic. Those columns have special meaning, and you cannot rename them or change their data type.
Additionally, we have 30 customizable columns that are labeled as Attribute1, Attribute2, etc. These are customizable fields and we will rename them to match the incoming columns of our CSV file. Since they’re not visible by default, let’s make them visible:
Click on
to select the fields to display.Display fields Attribute1 and Attribute2
Once you will need display more of them (or hide some of them), use the same approach.
Decide about the mapping
Your goal is to configure the Products master table in the way, so that it can hold data needed for your pricing project. So you need to decide, which fields of the Products table will hold content of which column from the provided data file.
The out-of-the-box fields:
The customizable Attribute# columns - Here you can store all other columns from the data file, which you really need to import. For example, let’s say you decided to use the following attribute fields:
-
Attribute1 - use it for Product Family
-
Attribute2 - use it for Business Unit
-
Attribute3 - use it for Product Category
-
Attribute4 - use it for Product Group
-
Attribute5 - use it for Product Type
-
Attribute6 - use it for Product Class
-
Attribute7 - use it for Discount Family
-
Attribute8 - use it for Industry
-
Attribute9 - use it for Product Group Id
Configure the Products Master Table fields
We recommend to set up the column labels, names and data-types according your dataset, as it’s the way how it will be used and shown in the solution. Here we show some particular example.
Configure the field Attribute1
-
To open the field context menu, right-click on the label for the Attribute1 column, or click on the … (this button appears only, when you hover the column label)
-
Click Rename and Customize Column. The dialog will appear.
-
Rename the field to "ProductFamily" (no spaces allowed in names)
-
Set the label to "Product Family", as it was in the datafile.
-
Set the Type to String
-
click on Confirm Changes. A confirmation will come up, so confirm the change.
-
Repeat the steps above for all the other columns in the CSV file using the following assignments (set both Name and Label for each field, where the Name cannot have spaces)
-
Attribute2 = Business Unit
-
Attribute3 = Product Category
-
Attribute4 = Product Group
-
Attribute5 = Product Type
-
Attribute6 = Product Class
-
Attribute7 = Discount Family
-
Attribute8 = Industry
-
Attribute9 = Product Group Id
-
Some of the columns in your data file will be aligned with some of the columns that are provided in the Products master table out-of-the-box. See the previous section about mapping. For such fields you can change only labels.
-
Change the label of the sku
-
To open the field context menu, right-click on the label for the Attribute1 column, or click on the … (this button appears only, when you hover the column label)
-
Click Rename and Customize Column. The dialog will appear.
-
change the Label to "Product Id"
-
keep the setting of Required as it is (most fields are not required).
-
click Confirm Changes. A confirmation will come up, so confirm the change.
-
-
Repeat the steps above for all the other columns in the CSV file using the following assignments:
-
label - set label "Product Name"
-
unitOfMeasure - set label "UOM"
-
currency - set label "Product Currency"
-
Fetch Products' Field metadata to your project
In case you already have your project set up in IntelliJ and also connection to partition set up, fetch the new fields' metadata to your project, so you can store it to Git.
Fetch the new fields' metadata to your project, including the Preferences.