解决方案:加一对中文的单引号,用两对因为引号包裹,直接加英文单引号会识别失败。
'‘'+i.POIName+'’'
select i.[POIID] as'兴趣点ID', '‘'+i.POIName+'’' as '兴趣点名称',
i.[CollectTime] as '采集时间', i.[POIAddress] as '兴趣点地址',
i.[Lon] as'经度', i.[Lat] as '纬度',c.CompanyName as '调查单位'
from T_InvestigatePOI as i
inner join T_InvestigatePath as p
on i.PathID =p.PathID
inner join T_TaskUser as tu
on p.TaskDetailID= tu.TaskDetailID
inner join T_Task as t
on tu.TaskID=t.TaskID
inner join T_Company as c
on c.CompanyID=t.CompanyID