title: Mapping to a collection of objects using XSLT from Legacy web service
body: <p>I am trying to populate xml using XSLT from data received from an external legacy web service which provides machine generated values for hotel information. They provide hotels with the element names having underscore and a number as shown below
    for example HotelName_1, HotelName_2 etc.  How do I to map these field names with underscores to my  elements?</p>
  
  <pre><code> &lt;!-- Web Service Results.. part of a larger schema, machine generated...--&gt;
      &lt;Hotel_Info&gt;
               &lt;Hotel_1&gt;
              &lt;HotelName_1&gt;La Quinta Inn&lt;/HotelName&gt;
              &lt;HotelAddressLine1Text_1&gt;552 12th Street West&lt;/HotelAddressLine1Text&gt;
              &lt;HotelCityName&gt;Dickinson_1&lt;/HotelCityName&gt;
              &lt;HotelStateCode_1&gt;ND&lt;/HotelStateCode&gt;
              &lt;HotelZip5Code_1&gt;58601&lt;/HotelZip5Code&gt;
              &lt;HotelZip4Code_1&gt;099&lt;/HotelZip4Code&gt;
               &lt;/Hotel_1&gt;
               &lt;Hotel_2&gt;
              &lt;HotelName_2&gt;&lt;/HotelName&gt;
              &lt;HotelAddressLine1Text_2&gt;3803 13th Ave S&lt;/HotelAddressLine1Text&gt;
              &lt;HotelCityName_2&gt;Fargo&lt;/HotelCityName&gt;
              &lt;HotelStateCode_2&gt;ND&lt;/HotelStateCode&gt;
              &lt;HotelZip5Code_2&gt;58103&lt;/HotelZip5Code&gt;
              &lt;HotelZip4Code_2&gt;099&lt;/HotelZip4Code&gt;
               &lt;/Hotel_2&gt;
               ....
      &lt;/Hotel_Info&gt;
  
    &lt;!-- Map to this schema     --&gt;
    &lt;AvailableHotels&gt;
       &lt;Hotel&gt;
      &lt;HotelName&gt;La Quinta Inn&lt;/HotelName&gt;
      &lt;HotelAddressLine1Text&gt;552 12th Street West&lt;/HotelAddressLine1Text&gt;
      &lt;HotelCityName&gt;Dickinson&lt;/HotelCityName&gt;
      &lt;HotelStateCode&gt;ND&lt;/HotelStateCode&gt;
      &lt;HotelZip5Code&gt;58601&lt;/HotelZip5Code&gt;
      &lt;HotelZip4Code&gt;099&lt;/HotelZip4Code&gt;
       &lt;/Hotel&gt;
       &lt;Hotel&gt;
      &lt;HotelName&gt;&lt;/HotelName&gt;
      &lt;HotelAddressLine1Text&gt;3803 13th Ave S&lt;/HotelAddressLine1Text&gt;
      &lt;HotelCityName&gt;Fargo&lt;/HotelCityName&gt;
      &lt;HotelStateCode&gt;ND&lt;/HotelStateCode&gt;
      &lt;HotelZip5Code&gt;58103&lt;/HotelZip5Code&gt;
      &lt;HotelZip4Code&gt;099&lt;/HotelZip4Code&gt;
       &lt;/Hotel&gt;
     &lt;/AvailableHotels&gt;
  </code></pre>