Partager via


Value Element

Within the Query element, the Value element contains the value against which the value returned by the FieldRef element is compared.

Syntax

<Value
  Type = "Text">
</Value>

Attributes

Name Description
Type Required Text. Specifies the data type for the value contained by this element.

Element Relationships

Parent Elements
DateRangesOverlap, Eq, Geq, Neq

Example

In the following example, the query returns cases where the BaseType field equals 1, and the Project field equals the ID of the current project property. Results are returned in ascending order, first by Title and then by ID.

<Query>
  <Where>
    <And>
      <Eq>
        <FieldRef Name="BaseType" />
        <Value Type="Integer">1</Value>
      </Eq>
      <Eq>
        <FieldRef Name="Project" />
        <Value Type="Integer">
          <ProjectProperty Select="ID" />
        </Value>
      </Eq>
    </And>
  </Where>
  <OrderBy>
    <FieldRef Name="Title" />
    <FieldRef Name="ID" />
  </OrderBy>
</Query>