Share via


Leq Element (Query)

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Arithmetic operator that means "less than or equal to." The Leq element is used in view queries similarly to the Eq and Geq elements.

<Leq>
  <FieldRef Name = "Field_Name"/>
  <Value Type = "Field_Type"/>
  <XML />
</Leq>

Attributes

Attribute

Description

None

N/A

Child Elements

FieldRef, Value, XML

Parent Elements

And, Or, Where

Occurrences

Minimum: 0

Maximum: Unbounded

Example

The following example queries for cases where the Expires field value either equals an empty string or is less than or equal to the current date.

<Query> 
  <Where> 
    <Or> 
      <IsNull> 
        <FieldRef Name="Expires" />  
      </IsNull> 
      <Leq> 
        <FieldRef Name="Expires" />  
        <Value Type="DateTime"> 
          <Today />  
        </Value> 
      </Leq> 
    </Or> 
  </Where> 
  <OrderBy> 
    <FieldRef Name="Modified" Ascending="FALSE" />  
  </OrderBy> 
</Query>

See Also

Reference

Geq Element (Query)

Eq Element (Query)

Gt Element (Query)

Lt Element (Query)

Neq Element (Query)