Storing Answer Options in Tables

When you want to offer users long lists of related options, you can store answers in product tables. By storing answers in tables, you can simplify the process of adding, removing, and updating the options for a question. For example, if your business sells desks, you can add several new desk types at the same time without creating a separate answer for each desk type.

These answer types can access product tables:

For more information about popup tables and popup lists, see Working with Popup Table and Popup List Answers.

These types of tables are available:

To create a table:

  1. In NetSuite, go to CPQ > Configurator > Product Maintenance.

  2. Click Edit next to the product you want to modify.

  3. On the Tables subtab, click New CPQC Table.

  4. Enter a descriptive name for the table.

    The name is used for internal reference only.

  5. In the Code field, enter a unique identifier for the table.

    The code can contain only uppercase letters, numbers, and underscores. You can enter a shortened version of the name as the code to identify the table in actions.

  6. Select a table type.

  7. Click Save.

After saving a table, you can edit it from the Tables subtab and modify its information or add new data. To copy or delete tables, see Working with Product Building Blocks.

Creating Static Tables

Static tables let you manually create and maintain a table in the table record. You can also enter JSON data in the JSON Data subtab and the table will be automatically displayed in the editor. The table editor and the subtab with JSON Data are synchronized. When you apply changes to one subtab, the other one is updated as well.

Note:

Static tables have a one million character limit. To create large tables, use the CSV table type.

You can also create a static table by importing data from a CSV file. For more information, see Importing Data Into Static Tables from CSV files.

Before completing the steps for this table type, follow the basic steps to create a table.

To create a static table:

  1. On the Tables subtab, click New CPQC Table.

  2. In the Table Type field, select Static Table.

  3. To enter data for the table, two options are available:

    • In the Table Editor subtab, click a row and enter text.

      Use the table editor buttons to add or remove rows and columns as needed.

    • In the JSON Data subtab, paste data in JSON format.

      For example, a table with two columns and three rows would have these structure:

                            [{"ColumnName1":"Value","ColumnName2":"Value"},{"ColumnName1":"Value","ColumnName2":"Value"},{"ColumnName1":"Value","ColumnName2":"Value"}] 
      
                          
  4. Click Save.

Importing Data Into Static Tables from CSV files

Instead of entering data manually, you can import data for a static table from a CSV file stored in the File Cabinet. Data will be saved in the table record.

Before completing the steps for this table type, follow the basic steps to create a table.

To create a static table from a CSV file:

  1. On the Tables subtab, click New CPQC Table.

  2. In the Table Type field, select Static Table.

  3. In the CSV File field, select the CSV file you want to use as the data source for the static table, for example, a comma or a semicolon.

  4. In the Column Separator field, select the symbol that separates the columns in the CSV file, for example, a comma or a semicolon.

  5. In the Escape Characters field, select the character used to indicate that the following character should be interpreted literally, or to enclose text with special characters.

  6. Click Save.

  7. On the Tables subtab, edit the table you've created to continue the setup.

  8. To unlink the CSV file after loading its data, check the Unlink static table from CSV file box.

    The static table will no longer be associated with the CSV file, and you can save the changes applied to the static table in the table record.

    If you clear this box, any changes you make to the static table on the table record will be disregarded.

    Note:

    Alternatively, you can unlink the static table from the CSV file by clearing the CSV File field after loading the data. Use this option if you don't need to keep track of the CSV file name.

  9. Click Save.

Creating CSV Tables

CSV tables retrieve data from CSV files stored in the File Cabinet. Unlike static tables, CSV tables don't store data in the table record and you can use them for large tables to avoid the one-million character limit. To update a CSV tables, you can upload a CSV file with the same name to the File Cabinet.

Before completing the steps to create a CSV table, follow the basic steps to create a table.

To create a CSV table:

  1. On the Tables subtab, click New CPQC Table.

  2. In the Table Type field, select CSV Table.

  3. In the CSV File field, select the CSV file you want to use as the data source.

  4. In the Column Separator field, select the symbol that separates the columns of the CSV file, for example, a comma or a semicolon.

  5. In the Escape Characters field, select the character used to indicate that the following character should be interpreted literally, or to enclose text with special characters.

  6. Click Save.

Creating Dynamic Tables

Dynamic tables retrieve data from the record type you specify. You can choose any record type available in your account, and the table content automatically updates whenever those records change. When users click the button of the popup table or list associated with the table, answer options are dynamically loaded from the table into these answer types.

To add content to a dynamic table, specify the record fields you want to include. Each field becomes a column in the table. If you don't specify any fields, the dynamic table remains empty. After defining the table content, you can filter the dynamic table by field value to narrow down the results and display only information that matches the criteria defined in popup tables or lists.

Note:

Record fields from sublists aren't available.

You can preview the content of the dynamic table by clicking the Test Table button.

Before completing the steps to create a dynamic table, follow the basic steps to create a table.

To create a dynamic table:

  1. On the Tables subtab, click New CPQC Table.

  2. In the Table Type field, select Dynamic Table.

  3. Select the record type from which you want to retrieve data.

  4. To add columns, click the plus icon next to the Record Fields field and select the record fields you want to include.

  5. To narrow down the table results and retrieve a subset of records, click the open icon next to the Search Filter field.

    In the popup wizard:

    • Select the record field you want to use for filtering.

    • Select an operator.

      The available operators depend on the field selected.

    • Enter the filter text.

    • Click OK.

  6. To add multiple filters and retrieve a more specific subset of records, repeat step 5.

    When adding another filter, you must select a logical operator (AND or OR) to combine the filters. AND produces a more restrictive condition, whereas OR results in a less restrictive condition.

    The filters are automatically copied to the Search Filter field in JSON format. The syntax is:

                      [["fieldID1","operator","value1"],"and",["fieldID2","operator","value2"]] 
    
                    
  7. To preview the dynamic table content, click the Test Table button.

  8. Click Save.

Creating Tables Using Functions

Function-generated tables (formerly called CE-generated tables) are dynamically created when you open a catalog. After creating this table type, you can use functions to fill it in when the product loads.

To create a function-generated table:

  1. Go to the Tables subtab.

  2. Click New CPQC Table.

  3. In the Table Type field, select Function-Generated Table.

  4. Click Save.

Related Topics

General Notices