Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 4.0

...

Code Block
  <select id="getResults1"
          parameterMap="select-parameters1" resultMap="select-results">
    <![CDATA[
        select receiveSynchronized, receiveTime, receiveTimeError, sendSynchronized, sendTime, send
TimeError, seqNum, timeType, timeValue, ttl 
        from clmp_owamp 
        where metadataId = ?
        and timeValue >= ?
        and timeValue <= ?
        order by timeValue ASC                                                                     
        
    ]]>
  </select>

which specifies a method call getResults1 which takes a parameter list defined in a (unshown) XML definition that specifies the required input parameters select-parameters1; and it gives out results in a (unshown) XML definition select-results.

...

Code Block
  <resultMap id="select-results" class="java.util.HashMap">
    <result property="value"      column="value" />
    <result property="timeValue"  column="timeValue" />
    <result property="valueUnits" column="valueUnits" />
  </resultMap>


  <parameterMap id="select-parameters1" class="java.util.HashMap">
    <parameter property="metadataId" />
    <parameter property="startTime" />
    <parameter property="endTime" />
  </parameterMap>


  <select id="getResults1"
          parameterMap="select-parameters1" resultMap="select-results">
    <![CDATA[
        select value, timeValue, valueUnits
        from perfsonar_utilization
        where metadataId = ?
        and timeValue >= ?
        and timeValue <= ?
        order by timeValue ASC
    ]]>
  </select>

Two mapping's are defined which are used in input and output parameters for the method call getResults1. select-results defines taht the properties are mapped to columns in the table definition for this utilisation data. (another file defines the location and accesss requirements of the SQL database).

...