ASP.NET下从MYSQL里面用存储过程取日期型数据出错.
一种情况是:select s.id,DATE_FORMAT(s.rundate ,'%Y-%c-%d') as rundate,s.runtime,s.status,s.failcode from mailstatus20090107 as s,mailsend20090107 as d where d.id=s.id and d.maildomain="live.cn" and d.mailuser="job.chang" and s.status= "success" order by d.runtime asc
到页面上显示出来的时候,rundate列就变成了System.Byte[]
另一种情况,select s.id,s.rundate,s.runtime,s.status,s.failcode from mailstatus20090107 as s,mailsend20090107 as d where d.id=s.id and d.maildomain="live.cn" and d.mailuser="job.chang" and s.status= "success" order by d.runtime asc
到页面上显示出来的时候,rundate列就变成了2009-01-09 0:00
如果用Gridview显示数据的话,可以用DataFormat限制一下或者用第一种方法就显示正常了,但是现在直接从DataTable导出为Excel,该怎么修正呢?
哪位可以指导一下,比较急啊...