title: Can anyone please tell me what's wrong in this caml query code?
body: <p>The Query:</p>
  
  <pre><code>&lt;Where&gt;
    &lt;Eq&gt;
      &lt;FieldRef Name='Document Type' LookupId='True' /&gt;            
      &lt;Value Type='Text'&gt;Standards(STA)&lt;/Value&gt;
    &lt;/Eq&gt;
  &lt;/Where&gt;
  &lt;OrderBy&gt;
   &lt;FieldRef Name='Number' Ascending='False'/&gt;
  &lt;/OrderBy&gt;
  &lt;RowLimit&gt;1&lt;/RowLimit&gt;"
  </code></pre>
  
  <p>Code Context:</p>
  
  <pre><code>&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"&gt;
  
  &lt;%@ Import Namespace="System.IO" %&gt;
  &lt;%@ Import Namespace="Microsoft.SharePoint" %&gt;
  &lt;%@ Page Language="C#" inherits="Microsoft.SharePoint.WebPartPages.WebPartPage, Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %&gt;
  &lt;%@ Register tagprefix="WebPartPages" namespace="Microsoft.SharePoint.WebPartPages" assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %&gt;
  &lt;%@ Register tagprefix="SharePoint" namespace="Microsoft.SharePoint.WebControls" assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %&gt;
  &lt;html&gt;
  
  &lt;head&gt;
  &lt;meta name="WebPartPageExpansion" content="full" /&gt;
  &lt;meta name="ProgId" content="SharePoint.WebPartPage.Document" /&gt;
  
  
  &lt;h1&gt;T-Site&lt;/h1&gt;
  
   &lt;script runat="server" type=""&gt;            
  
  protected void sevak(object sender, EventArgs e)
  
  string lastitem;
  try
  {
  
    using (SPSite objsite = new SPSite("http://..."))
    {
      using (SPWeb objWeb = objSite.OpenWeb())
      {
        SPList objList = objWeb.Lists["...."];
        SPQuery objQuery = new SPQuery();
  
        objQuery.Query = "&lt;Where&gt;&lt;Eq&gt;&lt;FieldRef Name='Document Type' LookupId='True' /&gt;            &lt;Value Type='Text'&gt;Standards(STA)&lt;/Value&gt;&lt;/Eq&gt;&lt;/Where&gt;&lt;OrderBy&gt;&lt;FieldRef Name='Number' Ascending='False'/&gt;&lt;/OrderBy&gt;&lt;RowLimit&gt;1&lt;/RowLimit&gt;";
  
        objQuery.Folder = objList.RootFolder;
        SPListItemCollection colItems = objList.GetItems(objQuery);
  
        if (colItems.Count&gt;0)
        {
          lastitem=colItems(0);
        }
        else 
        { 
          Label1.Text="noItem";
        }
      }
    }
  }
  catch (Exception ex)
  {
    return ex;
  }
  
  Label1.Text= "lastitem";
  </code></pre>
  
  <p>
  </p>
  
  <pre><code>&lt;SharePoint:CssLink runat="server"&gt;&lt;/SharePoint:CssLink&gt;
  &lt;SharePoint:ScriptLink runat="server" language="javascript" name="core.js"&gt;
  
  &lt;/SharePoint:ScriptLink&gt;
  
  &lt;body&gt;
  
  &lt;form id="form1" runat="server" action="Page-2.aspx"&gt;
  &lt;p&gt;
  
  
  &lt;asp:Button runat="server" Text="Submit" id="Button1" OnClick="sevak" &gt;&lt;/asp:Button&gt;
  
  
  &lt;/p&gt;
  &lt;p&gt;&lt;asp:Label runat="server" id="Label1"&gt;&lt;/asp:Label&gt;&lt;/p&gt;
  &lt;/form&gt;
  &lt;/body&gt;
  
  
  &lt;/html&gt;
  </code></pre>