6 Replies Latest reply: Aug 14, 2012 1:32 PM by 945963 RSS

    How to use comma separated values as separate dimensions

    945963
      Hello Everyone,

      We use text files as the data source for the baseline update in Endeca. We are adding 4-5 properties in the text file. Each property has comma separated values e.g. category property name has category1, category2, category3......category10 values. I have defined a dimension in my endeca workbench mapping the category property from text file to endeca dimension in the Workbench. But I want each of the categories to be treated as separate dimension values e.g. *"category1"*, *"category2"* ....*"category10"* for the category dimension and not just "*category1,category2, ...category10"* as one dimension value. Does anyone has any idea how to do it?

      Edited by: user8540737 on Jun 26, 2012 1:49 PM
        • 1. Re: How to use comma separated values as separate dimensions
          user5858891
          Hi There,

          even i am newbee in this world of experts but i think you shuold rethink your dimension for a better user experience.
          Dimension is a characterstic which sets a record apart from other's of the same family(e.g. wine Type).

          Having dimension which consist of multiple values is definately going to confuse end user.

          cheers
          • 2. Re: How to use comma separated values as separate dimensions
            Mandar Shastrakar
            Hi ,

            Please go through the wine app for more details on how to create dimension and properties and relate it to your scenario.

            HTH
            Mandar
            • 3. Re: How to use comma separated values as separate dimensions
              bplamondon
              @user5858891

              Dimensions are not required to have mutually exclusive values. Wine Type is a good example of a dimension that makes sense where the values will never overlap. However often there are reasons for dimensions that should be have multiple possibly overlapping values - such as Flavor as an example. A given wine might have flavors of honey, fruit, etc They may have many valid dimension values for a given dimension.

              Dimension values are meant to give a user the ability to filter down to what they are looking for - the user does not care about the exclusivity of a dimension value. Hope that helps clarify it.

              As for the original poster - I assume this has something specifically to do with the Product Catalog Integration DT so I am unable to assist there at this time.
              • 4. Re: How to use comma separated values as separate dimensions
                946644
                Use a manipulator after your input adapter. You can write expression (XML) to manipulate and split your dimension values from txt file and can map to single dimension.
                • 5. Re: How to use comma separated values as separate dimensions
                  Snolan-Oracle
                  Thanks for your question.

                  Your use case of reading in a packed list of values and wanting those values to be separated and mapped into a single Dimension is very common.

                  In your Endeca Developer Studio pipeline you can easily add a new Record Manipulator that performs a SPLIT function to accomplish what you need.

                  You can read more about how to create a Record Manipulator in the [Developer Studio Help Guide|http://docs.oracle.com/cd/E28912_01/DeveloperStudio.612/pdf/DevStudioHelp.pdf] . You can also learn more about the syntax for creating a SPLIT function in the [Data Foundry Expression Guide|http://docs.oracle.com/cd/E28912_01/DeveloperStudio.612/pdf/DataFoundryExpRef.pdf] .

                  For convenience, an example syntax...

                  <EXPRESSION TYPE="VOID" NAME="SPLIT">
                  <EXPRNODE NAME="OLD_NAME" VALUE="Category_PackedList"/>
                  <EXPRNODE NAME="NEW_NAME" VALUE="Category"/>
                  <EXPRNODE NAME="SPLIT" VALUE=","/>
                  <EXPRNODE NAME="ENUMERATE" VALUE="FALSE"/>
                  </EXPRESSION>
                  • 6. Re: How to use comma separated values as separate dimensions
                    945963
                    using the Split dimension manipulator worked. Here are the steps in order to use the functionality:
                    1. Create a new Dimension Manipulator in the Endeca workbench
                    2. Once the manipulator name has been set, click OK.
                    3. Double click on the newly created manipulator and add this code:

                    <EXPRESSION TYPE="VOID" NAME="SPLIT">
                    <EXPRNODE NAME="OLD_NAME" VALUE="The_Field_Name_from_data_file"/>
                    <EXPRNODE NAME="NEW_NAME" VALUE="The_new_name"/>
                    <EXPRNODE NAME="SPLIT" VALUE=","/>
                    <EXPRNODE NAME="ENUMERATE" VALUE="FALSE"/>
                    </EXPRESSION>