title: How to format Datetime? type to "yyyy-MM-dd"
body: <p>I query some field from database, the Planstartdate is datetime type, and the Planstartdate can be null, I want to format the Planstartdate  to "yyyy-MM-dd"</p>
  
  <pre><code>            DataTable dt = ds.Tables[0];
          var query = dt.AsEnumerable()
          .Select(dr =&gt;
          new InitOverview
          {
              IID = string.IsNullOrEmpty(dr.Field&lt;string&gt;("IID").ToString()) ? "" : dr.Field&lt;string&gt;("IID"),
              ProjectName = string.IsNullOrEmpty(dr.Field&lt;string&gt;("ProjectName")) ? "" : dr.Field&lt;string&gt;("ProjectName"),
              TeamLead = string.IsNullOrEmpty(dr.Field&lt;string&gt;("TeamLead")) ? "" : dr.Field&lt;string&gt;("TeamLead"),
              Status = string.IsNullOrEmpty(dr.Field&lt;string&gt;("Status")) ? "" : dr.Field&lt;string&gt;("Status"),
              OverallStatus = string.IsNullOrEmpty(dr.Field&lt;string&gt;("OverallStatus")) ? "" : dr.Field&lt;string&gt;("OverallStatus"),
              Planstartdate = dr.Field&lt;DateTime?&gt;("Planstartdate"),
              Planenddate = dr.Field&lt;DateTime?&gt;("Planenddate"),
              Actualstartdate = dr.Field&lt;DateTime?&gt;("Actualstartdate"),
              Actualenddate = dr.Field&lt;DateTime?&gt;("Actualenddate")
          }
          ).ToList();
  </code></pre>
  
  <p>anybody can help to realize it?
  Thanks</p>