SQL获取字段html代码中的img标签图片文件的路径

SELECT SUBSTRING(Description,0,PATINDEX('%"%',Description) as f
from(
select 
substring(InfoContent,patindex('%src="%',InfoContent)+5,patindex('%src="%',InfoContent)+5+PATINDEX('%" />%',substring(InfoContent,patindex('%src="%',InfoContent),len(InfoContent)-patindex('%src="%',InfoContent)))) as Description
from Tang_Information) as img

 

posted @ 2013-03-25 13:56  mikel  阅读(443)  评论(0编辑  收藏  举报