2 Replies Latest reply: May 4, 2010 2:18 PM by John Witherspoon RSS

    Linking Field values to the name of a field

    lauren.beale

      Is it possible to map a field value in a single field to equate to the names of other fields?

      For example, if I have a field (Store Names), which contains the names of various stores and then fields with the field names being that of each store and these field values contain sales numbers for the stores per day. If I want to add the store sales by choosing the store from the Store Name field, is it possible to map this field value to the actual field of that store name?

        • Linking Field values to the name of a field
          juergm

          Hi Lauren

          I might get you wrong but is it correct that you have a list(table) of stores and the sales in another table?

          For QlikView to relate the 2 tables the tables need to have a common field name, e.g. StoreId, If you have this the connection between selecting a store in the store list will automatically give you the sales for that store and selecting a sale will also show you from which store it sources.

          Juerg

            • Linking Field values to the name of a field
              John Witherspoon

              A crosstable load may be the easy way to map your data from its current layout to one that will allow QlikView to easily do what you're talking about. Basically, it converts all of your field names (the stores) to field values. So it's going in the opposite direction of what you're asking for, but I believe accomplishes the same thing overall.

              Assuming I didn't make a mistake, this:

              CROSSTABLE LOAD (Store, Sales)
              LOAD * INLINE [
              Store1, Store2, Store3, Store4
              500, 600, 700, 800
              ];

              Should give you this table:

              Store, Sales
              Store1, 500
              Store2, 600
              Store3, 700
              Store4, 800