This topic has not yet been rated - Rate this topic

Geq Element (Query)

Published: May 2010

Arithmetic operator that means "greater than or equal to." This element can be used within a Where element in a query.


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

Attribute

Description

None

N/A

Minimum: 0

Maximum: Unbounded

Remember that Collaborative Application Markup Language (CAML) is case-sensitive; note the lowercase "eq" in the Geq element name.

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

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

Date

Description

Reason

May 2010

Initial publication

Did you find this helpful?
(1500 characters remaining)
Community Content Add
Annotations FAQ