<p class="MsoNormal"><span lang="EN-US">@@</span><span style="">开头的是</span><span lang="EN-US">SQL Server</span><span style="">提供的全局变量</span><span lang="EN-US"><p></p></span></p>
<p class="MsoNormal"><span style="">常用的有</span><span lang="EN-US"><p></p></span></p>
<p class="MsoNormal"><span lang="EN-US"><span style=""></span>@@IDENTITY </span><span style="">刚插入的</span><span lang="EN-US">IDENTITY</span><span style="">字段的值</span><span lang="EN-US"><p></p></span></p>
<p class="MsoNormal"><span lang="EN-US">@@ROWCOUNT </span><span style="">前一个操作影响的行数</span><span lang="EN-US"><p></p></span></p>
<p class="MsoNormal"><span lang="EN-US">@@FETCH_STATUS </span><span style="">对游标的</span><span lang="EN-US">Fetch</span><span style="">操作是否成功</span> <span lang="EN-US"><p></p></span></p>
<p class="MsoNormal"><span lang="EN-US">@</span><span style="">开头的是变量名</span> <span lang="EN-US"><p></p></span></p>
<p class="MsoNormal"><span lang="EN-US"><p></p></span></p>
<p class="MsoNormal"><span lang="EN-US">#</span><span style="">开头的是局部临时表,只在当前连接中有用</span><span lang="EN-US"><p></p></span></p>
<p class="MsoNormal"><span lang="EN-US">##</span><span style="">开头的是全局临时表,在数据库服务器重启之前都有用</span> <span lang="EN-US"><p></p></span></p>
<p class="MsoNormal"><span lang="EN-US"><p></p></span></p>