Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This Output Kind was introduced in Perfion 4.5 2019 R1, and should not be confused with outputting an attribute as a Field as described in Section Field where an attribute from a Perfion Query Result is output as a Field.

The Output Kind Attribute is used to “decorate” an already existing Output-element with an attribute.

Attribute

What can be output

Supports

Supported Entities

a Features

a Attributes

a Literals

r Multi value features (First from Perfion 2024 R1 SR2)

a Localizable features

r Output Kind Parameters

a Site

a Category

a Product

a Variant

Sample Mappings

 

 

Sample output

Code Block
<Response>
   <Result>
   <TotalCount>1</TotalCount>
   <Product>
      <!-- Fields from ERP and Perfion omitted here for brevity -->
      <field name="NoOfCups" value="4" size="Medium" /> 
      <field name="Volume" value="0.35" unit="L" />
   </Product>
   </Result>
</Response>

 

Table 1: Summary of Output Kind Attribute.

Notice the mapping with Output Kind Attribute. In the example in Table 1 the value of the feature CupSize is mapped to an element named NoOfCups@size an attribute named size. The “@” makes sure that the data get’s mapped on an attribute on the output field and not as a separate output field.

It even works for fields originating from a *-mapping. In addition, fields having their data coming from a Literal or Attribute can be decorated.

It is not only Fields that can be output using the Attribute Output Kind. Also Image-, Attachment-, Url-, RelatedProduct- and RelatedCategory-elements can be decorated.

Info

NOTE: Do not use attribute names id, parentId, name, perfionname, culture, modifieddate, ecommerceproduct and ecommercevariant, since the ECommerce API already uses them.

Combining non-localizable with localizable features on fields and attributes

It is worth looking into localizable features and combining localizable features with non-localizable features. In Table 1 we combined NoOfCups and CupSize-features that happened both to be non-localizable. Similarly combining two features that are both localizable works as expected. However, what about making a localizable feature and map it to a Field while a non-localizable is output as an Attribute on that same Field. How would that work? Let us consider the remaining 3 localization-combinations in the following example:

Example

Consider the following data on a product:

ItemName- and Color-features are localizable. While RRP (RetailPrice) and RetailPriceCurrency are not. For the sake of simplicity, assume that we have two languages in play: English and German.

Let us see how the possible combinations are handled by the ECommerce API:

Combining two localizable features

Mappings

 

Image RemovedImage Added

 

Description

Both ItemName and Color are localizable features, so for each language the ItemName is output as a separate Field named Title for each culture. This makes it obvious that each localizable Color-value-attribute should be put on the Field matching the culture. I.e. the English Color is matched with the English Title and output here.

 

Result

 

Code Block
<Product id="636" ecommerceproduct="983ST">
  <Fields>
    …
    <Field name="Title" color="Yellow" culture="en-US">Vacuum Jug EM77 Yellow</Field>
    <Field name="Title" color="Gelb" culture="de-DE">Vacuum Jug EM77 Gelb</Field>
    …
  </Fields>
</Product>

 

Combining a localizable Field with a non-localizable attribute

Mappings

 

Image RemovedImage Added

 

Description

Here the localizable ItemName still outputs a Field named Title for each language/culture. The non-localizable RetailPriceCurrency is simply added to each one.

 

Result

       

Code Block
<Product id="636" ecommerceproduct="983ST">
  <Fields>
    …
    <Field name="Title" currency="Euro" culture="en-US">Vacuum Jug EM77 Yellow</Field>
    <Field name="Title" currency="Euro" culture="de-DE">Vacuum Jug EM77 Gelb</Field>
    …
  </Fields>
</Product>

 

Combining a non-localizable Field with a localizable attribute

Mappings

 

Image RemovedImage Added

 

Description

Here the non-localizable feature RetailPrice is given the localizable feature Color as attribute. Since RetailPrice is only output once, color is output only once. The ECommerce API picks the value of the primary language which is the first language specified in Settings (See Languages-setting).

 

Result

 

Code Block
<Product id="636" ecommerceproduct="983ST">
  <Fields>
    …
    <Field name="RetailPrice" color="Yellow">49.95</Field>
    …
  </Fields>
</Product>

 

Table 1: 3 of the 4 different combinations of localizability of 2 features.

The last combination should be avoided, since it does not output localizable data other than that in default language (in Table 1 it is the colors in any language but English that are lost). Unfortunately, this hits the often-wanted combination of outputting some sort of measure combined with its unit. Consider this example:

Code Block
<Field name="TopSpeed" unit="km/h">206</Field>

 

Here TopSpeed is assumed to be non-localizable and TopSpeedUnit to be localizable (since it would be “Kilometers per hour” or “km/h” in English and “Kilometers pro Stunde” or “km/s” in German). However, as we saw from Table 1, this combination gives us problems. There are multiple solutions to this:

 

Solution #1: Output both as Fields 

Code Block
    <Field name="TopSpeed">206</Field>
    <Field name="TopSpeedUnit" culture="en-US">km/h</Field>
    <Field name="TopSpeedUnit" culture="de-DE">km/s</Field>

Here the foreign system must somehow know how to connect the two.

Solution #2: Make TopSpeed localizable and give it same value in all languages 

Code Block
    <Field name="TopSpeed" unit="km/h" culture="en-US">206</Field>
    <Field name="TopSpeed" unit="km/s" culture="de-DE">206</Field>

This gives the result wanted, but forces users to maintain the same value for all languages.

Solution #3: Same as Solution #2 but using a self-remote to output same value in all languages

This outputs the same as Solution 2. The idea is to make a self-remote, that is a query “localizing” all features you need to pair up with their appropriate units. It is beyond the scope of this document to describe how to do a self-remote in Perfion. Consult Perfion to get help if you are in doubt.

Outputting Multi Value-attributes (Requires Perfion 2024 R1 SR2)

From Perfion 2024 R1 SR2 it is now possible to use multi value features to create attributes on multi value outputs. This can for example be used to give a multi value image feature a caption or maybe an “alternative text” or maybe a multi value attachment a nice display name to be used on a link. It works both for localizable and non-localizable features and it even works when combining multi value image-/attachment-features.

In the following we will take a look at some examples.

Adding description-attributes to a multi value image-feature

Mappings

image-20240529-122245.png

Description

Here WebImages is a multi value, explicit image feature and WebImageDescription is a multi value, explicit string feature. Both features have “Sortable” checked in Perfion, since the images are paired with strings using their position. The image below shows a single product holding 3 WebImages with 3 WebImageDescriptions. Notice how each image matches its description by their position in the lists.

image-20240529-121822.png

Result

Code Block
<Product id="6672" ecommerceproduct="Example 1">
  <Fields>
    <Field name="Id">Example 1</Field>
    <Field name="Title" culture="en-US">Grindenstein Knock Box</Field>
  </Fields>
  <Images>
    <Image name="Images" perfionname="WebImages" description="Black Knock Box by Grindenstein">
      <Guid>d6ff7245-899c-4573-9a90-5bbd1b590e62</Guid>
      <OriginalFileName>Grindenstein Black.jpg</OriginalFileName>
      <Url>...</Url>
    </Image>
    <Image name="Images" perfionname="WebImages" description="Grey Knock Box by Grindenstein">
      <Guid>ba4f290c-6def-41e8-9796-9c4131429791</Guid>
      <OriginalFileName>Grindenstein Grey.jpg</OriginalFileName>
      <Url>...</Url>
    </Image>
    <Image name="Images" perfionname="WebImages" description="Red Knock Box by Grindenstein">
      <Guid>8947bb9f-c273-4427-9eef-b5c0d4d43038</Guid>
      <OriginalFileName>Grindenstein Red.jpg</OriginalFileName>
      <Url>...</Url>
    </Image>
  </Images>
</Product> 

Notice, by looking at the “OriginalFileName” how each description is added to the correct Image-output in a description-attribute.

Notice how each description is added to the Image-output in a description-attribute.

The same can be done for localizable images. Here it is allowed to have a different number of image in each language. The important thing is that the number of images in some language must match the number of descriptions in that language.

Adding description-attributes to a localizable, multi value image-feature

Mappings

image-20240529-130545.png

Description

Here LocalizableWebImages is a multi value, localizable, explicit image feature and LocalizableWebImageDescription is a multi value, localizable, explicit string feature. Both features have “Sortable” checked in Perfion, since the images are paired with strings using their position, it is important that both can be manualle sorted. The image below shows a single product holding 3 LocalizableWebImages with 3 LocalizableWebImageDescriptions. Notice how each image in each language matches its description by their language and position in the lists.

image-20240529-131244.png

Notice that the English value only holds 2 images while the German holds 3. This is fine, as long as the number of descriptions matches in each language.

Result

Code Block
<Product id="6682" ecommerceproduct="Example 2">
  <Fields>
    <Field name="Id">Example 2</Field>
    <Field name="Title" culture="en-US">BMW</Field>
    <Field name="Title" culture="de-DE">BMW</Field>
  </Fields>
  <Images>
   <Image name="Images" perfionname="LocalizableWebImages" culture="en-US" description="Blue BMW">
      <Guid>5c4cc66c-61cf-43b3-9c50-07d38d544d6c</Guid>
      <OriginalFileName>Blue BMW.jpg</OriginalFileName>
      <Url>....</Url>
    </Image>
    <Image name="Images" perfionname="LocalizableWebImages" culture="en-US" description="White BMW">
      <Guid>ad27bdf4-b1b3-4585-8f79-96ee8e8b0918</Guid>
      <OriginalFileName>White BMW.jpg</OriginalFileName>
      <Url>....</Url>
    </Image>
    <Image name="Images" perfionname="LocalizableWebImages" culture="de-DE" description="Rot BMW">
      <Guid>4a6b6f07-bcaf-40d3-99e2-e0f3d3a67246</Guid>
      <OriginalFileName>Rot BMW.jpg</OriginalFileName>
      <Url>....</Url>
    </Image>
    <Image name="Images" perfionname="LocalizableWebImages" culture="de-DE" description="Weiss BMW">
      <Guid>b3d08d98-deee-44ec-b8ee-059ed4217d27</Guid>
      <OriginalFileName>Weiss BMW.jpg</OriginalFileName>
      <Url>....</Url>
    </Image>
    <Image name="Images" perfionname="LocalizableWebImages" culture="de-DE" description="Blau BMW">
      <Guid>fddfe993-7f84-4fe4-ac86-ab58dc8deb5a</Guid>
      <OriginalFileName>Blau BMW.jpg</OriginalFileName>
      <Url>....</Url>
    </Image>
  </Images>
</Product>

Notice, by looking at the “OriginalFileName” how each description is added to the correct Image-output in a description-attribute.

Table of Contents

The final example shows how multiple image features may be combined and still have their description attribute set. This requires a string-feature for each Image-feature. For simplicity the example combines two non-localizable Image-features, but they might as well have been localizable.

This Output Kind was introduced in Perfion 4.5 2019 R1, and should not be confused with outputting an attribute as a Field as described in Section Field where an attribute from a Perfion Query Result is output as a Field.

The Output Kind Attribute is used to “decorate” an already existing Output-element with an attribute.

Attribute

What can be output

Supports

Supported Entities

a Features

a Attributes

a Literals

r Multi value features (First from Perfion 2024 R1 SR2)

a Localizable features

r Output Kind Parameters

a Site

a Category

a Product

a Variant

Sample Mappings

 

 

Sample output

Code Block
<Response>
   <Result>
   <TotalCount>1</TotalCount>
   <Product>
      <!-- Fields from ERP and Perfion omitted here for brevity -->
      <field name="NoOfCups" value="4" size="Medium" /> 
      <field name="Volume" value="0.35" unit="L" />
   </Product>
   </Result>
</Response>

 

Table 1: Summary of Output Kind Attribute.

Notice the mapping with Output Kind Attribute. In the example in Table 1 the value of the feature CupSize is mapped to an element named NoOfCups@size an attribute named size. The “@” makes sure that the data get’s mapped on an attribute on the output field and not as a separate output field.

It even works for fields originating from a *-mapping. In addition, fields having their data coming from a Literal or Attribute can be decorated.

It is not only Fields that can be output using the Attribute Output Kind. Also Image-, Attachment-, Url-, RelatedProduct- and RelatedCategory-elements can be decorated.

Info

NOTE: Do not use attribute names id, parentId, name, perfionname, culture, modifieddate, ecommerceproduct and ecommercevariant, since the ECommerce API already uses them.

Combining non-localizable with localizable features on fields and attributes

It is worth looking into localizable features and combining localizable features with non-localizable features. In Table 1 we combined NoOfCups and CupSize-features that happened both to be non-localizable. Similarly combining two features that are both localizable works as expected. However, what about making a localizable feature and map it to a Field while a non-localizable is output as an Attribute on that same Field. How would that work? Let us consider the remaining 3 localization-combinations in the following example:

Example

Consider the following data on a product:

ItemName- and Color-features are localizable. While RRP (RetailPrice) and RetailPriceCurrency are not. For the sake of simplicity, assume that we have two languages in play: English and German.

Let us see how the possible combinations are handled by the ECommerce API:

Combining two localizable features

Mappings

 

 

Description

Both ItemName and Color are localizable features, so for each language the ItemName is output as a separate Field named Title for each culture. This makes it obvious that each localizable Color-value-attribute should be put on the Field matching the culture. I.e. the English Color is matched with the English Title and output here.

 

Result

 

Code Block
<Product id="636" ecommerceproduct="983ST">
  <Fields>
    …
    <Field name="Title" color="Yellow" culture="en-US">Vacuum Jug EM77 Yellow</Field>
    <Field name="Title" color="Gelb" culture="de-DE">Vacuum Jug EM77 Gelb</Field>
    …
  </Fields>
</Product>

 

Combining a localizable Field with a non-localizable attribute

Mappings

 

 

Description

Here the localizable ItemName still outputs a Field named Title for each language/culture. The non-localizable RetailPriceCurrency is simply added to each one.

 

Result

       

Code Block
<Product id="636" ecommerceproduct="983ST">
  <Fields>
    …
    <Field name="Title" currency="Euro" culture="en-US">Vacuum Jug EM77 Yellow</Field>
    <Field name="Title" currency="Euro" culture="de-DE">Vacuum Jug EM77 Gelb</Field>
    …
  </Fields>
</Product>

 

Combining a non-localizable Field with a localizable attribute

Mappings

 

 

Description

Here the non-localizable feature RetailPrice is given the localizable feature Color as attribute. Since RetailPrice is only output once, color is output only once. The ECommerce API picks the value of the primary language which is the first language specified in Settings (See Languages-setting).

 

Result

 

Code Block
<Product id="636" ecommerceproduct="983ST">
  <Fields>
    …
    <Field name="RetailPrice" color="Yellow">49.95</Field>
    …
  </Fields>
</Product>

 

Table 1: 3 of the 4 different combinations of localizability of 2 features.

The last combination should be avoided, since it does not output localizable data other than that in default language (in Table 1 it is the colors in any language but English that are lost). Unfortunately, this hits the often-wanted combination of outputting some sort of measure combined with its unit. Consider this example:

Code Block
<Field name="TopSpeed" unit="km/h">206</Field>

 

Here TopSpeed is assumed to be non-localizable and TopSpeedUnit to be localizable (since it would be “Kilometers per hour” or “km/h” in English and “Kilometers pro Stunde” or “km/s” in German). However, as we saw from Table 1, this combination gives us problems. There are multiple solutions to this:

 

Solution #1: Output both as Fields 

Code Block
    <Field name="TopSpeed">206</Field>
    <Field name="TopSpeedUnit" culture="en-US">km/h</Field>
    <Field name="TopSpeedUnit" culture="de-DE">km/s</Field>

Here the foreign system must somehow know how to connect the two.

Solution #2: Make TopSpeed localizable and give it same value in all languages 

Code Block
    <Field name="TopSpeed" unit="km/h" culture="en-US">206</Field>
    <Field name="TopSpeed" unit="km/s" culture="de-DE">206</Field>

This gives the result wanted, but forces users to maintain the same value for all languages.

Solution #3: Same as Solution #2 but using a self-remote to output same value in all languages

This outputs the same as Solution 2. The idea is to make a self-remote, that is a query “localizing” all features you need to pair up with their appropriate units. It is beyond the scope of this document to describe how to do a self-remote in Perfion. Consult Perfion to get help if you are in doubt.

Outputting Multi Value-attributes (Requires Perfion 2024 R1 SR2)

From Perfion 2024 R1 SR2 it is now possible to use multi value features to create output attributes on multi value outputs-feature output. This can for example be used to give a multi value image feature a caption on each image or maybe an “alternative text” or maybe a . It can also be used to give multi value attachment attachments a nice display name title to be used on a link. It Outputting multi value features works both for localizable and non-localizable features and it even works when combining two or more multi value image-/attachment-features.

In the following we will take a look at some examples.

Adding description-attributes to a multi value image-feature

Mappings

image-20240529-122245.pngImage Removed

Description

Here

In the the first example WebImages is a multi value, explicit image feature and

WebImageDescription

WebImageDescriptions is a multi value, explicit string feature.

Both

Importantly, both features have “Sortable” checked in Perfion, since the images are paired with the strings using their position. The image below shows a single product holding 3 WebImages with 3 WebImageDescriptions. Notice how each image matches its description by their position in the lists.

image-20240529-121822.pngImage RemovedResult

Adding description-attributes to a multi value image-feature

Mappings

image-20240529-122245.pngImage Added

Description

Sample output product “Example 1” to output in the result below:

image-20240529-121822.pngImage Added

Result

Code Block
<Product id="6672" ecommerceproduct="Example 1">
  <Fields>
    <Field name="Id">Example 1</Field>
    <Field name="Title" culture="en-US">Grindenstein Knock Box</Field>
  </Fields>
  <Images>
    <Image name="Images" perfionname="WebImages" description="Black Knock Box by Grindenstein">
      <Guid>d6ff7245-899c-4573-9a90-5bbd1b590e62</Guid>
      <OriginalFileName>Grindenstein Black.jpg</OriginalFileName>
      <Url>...</Url>
    </Image>
    <Image name="Images" perfionname="WebImages" description="Grey Knock Box by Grindenstein">
      <Guid>ba4f290c-6def-41e8-9796-9c4131429791</Guid>
      <OriginalFileName>Grindenstein Grey.jpg</OriginalFileName>
      <Url>...</Url>
    </Image>
    <Image name="Images" perfionname="WebImages" description="Red Knock Box by Grindenstein">
      <Guid>8947bb9f-c273-4427-9eef-b5c0d4d43038</Guid>
      <OriginalFileName>Grindenstein Red.jpg</OriginalFileName>
      <Url>...</Url>
    </Image>
  </Images>
</Product> 

Notice, by comparing the value in description-attribute with the “OriginalFileName” how each description is added to the correct Image output in a description-attribute.

Notice how each description is added to the Image-output in a description-attribute.

The next example shows that the same can be done for localizable images. Here Features LocalizableWebImages and LocalizableWebImageDescriptions are, as their names imply, multivalue, localizable features being an Image and a String-feature, respectively. Note how it is allowed to have a different number of image in images for each language. The important thing is that the number of images in some language must match matches the number of descriptions in that language.

Adding localizable description-attributes to

when combining multiple

a localizable multi value image-

features

feature

Mappings

image-20240529-133734.pngImage Removed

Notice the small trick used to let the ECommerce API know which “description-feature” goes with which “image-feature”. The trick is simply to add the feature name in parenthesis after the Field-name (here Images).

Description

Here WebImages and MoreWebImages are both multi value, explicit image features and both WebImageDescriptions MoreWebImageDescriptions are multi value, explicit string features. All 4 features have “Sortable” checked in Perfion, since the images are paired with strings using their position, it is important that both can be manualle sorted. The image below shows a single product holding 2 WebImages and 3 MoreWebImages with their corresponding “WebImageDescription-features”. Notice how each image matches its description in its corresponding description-feature.
image-20240530-063356.pngImage Added

Description

Sample output product “Example 2” to output in the result below:

image-20240530-063627.pngImage Added

Result

Code Block
<Product id="6682" ecommerceproduct="Example 2">
  <Fields>
    <Field name="Id">Example 2</Field>
    <Field name="Title" culture="en-US">BMW</Field>
    <Field name="Title" culture="de-DE">BMW</Field>
  </Fields>
  <Images>
    <Image name="Images" perfionname="LocalizableWebImages" culture="en-US" description="Blue BMW">
      <Guid>5c4cc66c-61cf-43b3-9c50-07d38d544d6c</Guid>
      <OriginalFileName>Blue BMW.jpg</OriginalFileName>
      <Url>...</Url>
    </Image>
    <Image name="Images" perfionname="LocalizableWebImages" culture="en-US" description="White BMW">
      <Guid>ad27bdf4-b1b3-4585-8f79-96ee8e8b0918</Guid>
      <OriginalFileName>White BMW.jpg</OriginalFileName>
      <Url>...</Url>
    </Image>
    <Image name="Images" perfionname="LocalizableWebImages" culture="de-DE" description="Rot BMW">
      <Guid>4a6b6f07-bcaf-40d3-99e2-e0f3d3a67246</Guid>
      <OriginalFileName>Rot BMW.jpg</OriginalFileName>
      <Url>...</Url>
    </Image>
    <Image name="Images" perfionname="LocalizableWebImages" culture="de-DE" description="Weiss BMW">
      <Guid>b3d08d98-deee-44ec-b8ee-059ed4217d27</Guid>
      <OriginalFileName>Weiss BMW.jpg</OriginalFileName>
      <Url>...</Url>
    </Image>
    <Image name="Images" perfionname="LocalizableWebImages" culture="de-DE" description="Blau BMW">
      <Guid>fddfe993-7f84-4fe4-ac86-ab58dc8deb5a</Guid>
      <OriginalFileName>Blau BMW.jpg</OriginalFileName>
      <Url>...</Url>
    </Image>
  </Images>
</Product>

Notice, by comparing the value in description-attribute with the “OriginalFileName” how each description is added to the correct Image output in a description-attribute.

The final example of adding multi value attributes to multi value images shows how two multi value image-features can be combined to one output (below named “Images”) can still have a description added. In the below example WebImages and MoreWebImages are both multi value, explicit image features and both WebImageDescriptions MoreWebImageDescriptions are multi value, explicit string features. All 4 features have “Sortable” checked in Perfion, since the images are paired with strings using their position, it is important that both can be manually sorted. The image below shows a single product holding 2 WebImages and 3 MoreWebImages with their corresponding “WebImageDescription-features” holding the exact same number of strings.

It is important to notice the small trick that tells the ECommerce API that descriptions for WebImages can be found in WebImageDescriptions and that those for MoreWebImages can be found in MoreWebImageDescriptions. The trick is simply to mention the originating feature in parenthesis after the “Output To”-name. So for WebImageDescriptions we output to Images(WebImages)@description instead of just Images@description. Same is done for MoreWebImages and MoreWebImageDescriptions.

Adding description-attributes to when combining multiple multi value image-features

Mappings

image-20240529-133734.pngImage Added

Notice the small trick used to let the ECommerce API know which “description-feature” goes with which “image-feature”. The trick is simply to add the feature name in parenthesis after the To-name (here Images).

Description

image-20240529-134221.pngImage Modified

Result

Code Block
<Product id="6685" ecommerceproduct="Example 3">
  <Fields>
    <Field name="Id">Example 3</Field>
    <Field name="Title" culture="en-US">BMW</Field>
    <Field name="Title" culture="de-DE">BMW</Field>
  </Fields>
  <Images>
    <Image name="Images" perfionname="WebImages" description="Blue BMW">
      <Guid>99bd0d48-7f76-4e7a-b3f6-e3faf6285789</Guid>
      <OriginalFileName>Blue BMW.jpg</OriginalFileName>
      <Url>http://api.local/Perfion/Image.aspx?id=99bd0d48-7f76-4e7a-b3f6-e3faf6285789&amp;format=jpg&amp;size=1024x1024<<Url>...</Url>
    </Image>
    <Image name="Images" perfionname="WebImages" description="Red BMW">
      <Guid>ee2e27b6-9796-4208-8007-07c8e4d31e84</Guid>
      <OriginalFileName>Red BMW.jpg</OriginalFileName>
      <Url>http://api.local/Perfion/Image.aspx?id=ee2e27b6-9796-4208-8007-07c8e4d31e84&amp;format=jpg&amp;size=1024x1024<<Url>...</Url>
    </Image>
    <Image name="Images" perfionname="MoreWebImages" description="Forrest">
      <Guid>b84afe86-1316-4ac7-a86d-59a0f3ade1c2</Guid>
      <OriginalFileName>BMW Forrest.jpg</OriginalFileName>
      <Url>http://api.local/Perfion/Image.aspx?id=b84afe86-1316-4ac7-a86d-59a0f3ade1c2&amp;format=jpg&amp;size=1024x1024<
      <Url>...</Url>
    </Image>
    <Image name="Images" perfionname="MoreWebImages" description="Happy people">
      <Guid>a046376b-53a5-4c6a-a86f-933b1a5f76f9</Guid>
      <OriginalFileName>BMW Happy People.jpg</OriginalFileName>
      <Url>http://api.local/Perfion/Image.aspx?id=a046376b-53a5-4c6a-a86f-933b1a5f76f9&amp;format=jpg&amp;size=1024x1024<<Url>...</Url>
    </Image>
    <Image name="Images" perfionname="MoreWebImages" description="Technical drawing">
      <Guid>c8297fac-dc19-4194-9dee-a359bfd198d6</Guid>
      <OriginalFileName>BMW Technical.jpg</OriginalFileName>OriginalFileName>
      <Url>...</Url>
    </Image>
      <Url>http://api.local/Perfion/Image.aspx?id=c8297fac-dc19-4194-9dee-a359bfd198d6&amp;format=jpg&amp;size=1024x1024</Url>
    </Image>
  </Images>
</Product>
Notice, by looking at the “OriginalFileName” how each description is added to the correct Image output in a description-attribute
</Images>
</Product>

Notice, by looking at the “OriginalFileName” how each description is added to the correct Image output in a description-attribute.

Final note on multi value attributes

The above examples show adding attributes to Images. The exaxt same thing can be done for Attachments and Urls and to some extend also Fields. Fields cannot be combined (ie. multiple features being mapped to same Field) so attributes cannot be combined either.

All examples emphasize that you need the same number of values in the “Attribute feature” as in the Feature you want to decorate. That obviously makes sense. Should you have an extra value (an extra description) it will not be used, and should you miss a value (miss a description) the last value in the output will not de decorated (i.e. the last image will not get a description).

Table of Contents