SQL Server静态页面导出技术3
2024-08-31 00:48:48
供稿:网友
border="border" align="center"><th><tr><h2>'+convert(varchar(4),@year)+
'年'[email protected]+'月份</h2></tr></th><tr><td>星期日</td><td>星期一</td><td>星期二</td><td>星期三</td><td>星期四</td><td>星期五</td><td>星期六</td></tr>')
else
insert into ##daylist
values('</tr></table><table border="border" align="center"><th><tr><h2>'+
convert(varchar(4),@year)+'年'[email protected]+'月份</h2></tr></th><tr><td>星期日</td><td>星期一</td><td>星期二</td><td>星期三</td><td>星期四</td><td>星期五</td><td>星期六</td></tr>')
end
if @tt<>0
if @xingqi < 7
set @[email protected]+'<td><a href="'[email protected]+'/index.htm" target="new">'+convert(varchar(2), @ri)+'</a></td>'
else
set @[email protected]+'<td><a href="'[email protected]+'/index.htm" target="new">'+convert(varchar(2), @ri)+'</a></td></tr><tr>'
else
begin
set @tt=1
set @outchar=
case
when @xingqi=1 then ''
when @xingqi=2 then '<td></td>'
when @xingqi=3 then '<td></td><td></td>'
when @xingqi=4 then '<td></td><td></td><td></td>'
when @xingqi=5 then '<td></td><td></td><td></td><td></td>'
when @xingqi=6 then '<td></td><td></td><td></td><td></td><td></td>'
when @xingqi=7 then '<td></td><td></td><td></td><td></td><td></td><td></td>'
end
if @xingqi < 7
set @[email protected]+'<td><a href="'[email protected]+'/index.htm" target="new">'+convert(varchar(2), @ri)+'</a></td>'
else
set @[email protected]+'<td><a href="'[email protected]+'/index.htm" target="new">'+convert(varchar(2), @ri)+'</a></td></tr><tr>'
end
insert into ##daylist values(@outchar)
set @[email protected]
set @outchar=''
fetch point3 into
@dy,@date,@yue,@ri,@xingqi,@year
end
close point3
deallocate point3
execute sp_makewebtask
@outputfile='d:/test/daylist.htm',
@query='select * from ##daylist',
@templatefile='d:/test/rili.tml',
@codepage=936
drop table ##daylist
首先请读者通读上面的代码,以便对它有一个大概的了解。下中国最大的web开发资源网站及技术社区,