title: Adding search and time stamp filter to Elastic Search Nest client
body: <p>I want to search and filter data using c# Nest client 
  Below is the query written using  Javascript-Elastic search and similar client i am trying to write in c# but its not working as expected</p>
  
  <p>Javascript Elastic Search client :</p>
  
  <pre><code>    var from_ms = from.getTime();
      var to_ms = to.getTime();
      var query = 'temp:' + Temp + ' AND url:"type=' + value + '"';
      client.search({
      type: 'Type',
      size: 5000,
      q: query,
      body: {
          sort: [
          {
              "@timestamp": {
                  "order": "desc"
              }
          }
          ],
          filter: {
              "range": {
                  "@timestamp": {
                      "from": from_ms,
                      "to": to_ms
                  }
              }
              //"range": { "@timestamp": { "from": 1444118389, "to": 1444120189 }} 
          }
      }
  
  }).
  </code></pre>
  
  <p>C# Elastic Search code i tried but its not working as expected 
  I am not getting how can i add the query in c# as i have in JS and how to filter data using time stamp</p>
  
  <pre><code>    class ElasticearchQuery
  {
      public class REstt
      {
          public string test{ get; set; }
  
          public string url { get; set; }
  
      }
  
      static void Main(string[] args)
      {
          try
          {
              var connection = new X509CertificateHttpConnection();
              var connectionPool = new SingleNodeConnectionPool(new Uri("https://www.yy.com"));
              var settings = new ConnectionSettings(connectionPool, connection);
              var client = new ElasticClient(settings);
              REstt person = new REstt();
              QueryContainer query = new TermQuery()
              {
                  Field = "temp",
                  Value = "value"
              };
  
  
              var searchRequest = new SearchRequest
              {
                  From = 0,
                  Size = 5000,
                  Query = query
              };
              var searchResults = client.Search&lt;REstt&gt;(searchRequest);
              var temp = searchResults.Hits;
  
  
              Console.WriteLine(temp);
  
          }
          catch (Exception e)
          {
          }
      }
  </code></pre>
  
  <p>}</p>