Access中的语句:
Sql Server通配符: % 多个 _1个
Accesss通配符: *多个 ?1个
-------
Access中能执行
SELECT T_StockNoticeInfo.StockID, IIf(CreateTime Like '2011/10/14 ??:??:??',format(LeadingStockIndex,'0.00'),format(0,'0.00')) AS [2011/10/14],IIf(CreateTime Like '2011/10/13 ??:??:??',format(LeadingStockIndex,'0.00'),format(0,'0.00')) AS [2011/10/13] FROM T_StockNoticeInfo
在程序中执行, 却不行, 需要把??换成Sql Server的通配符__
然后就行了
简单, 标记下, 怕忘