悬赏园豆:40
[已关闭问题]
<h2>SQL难题</h2>
<div id="postmessage_144256" class="t_msgfont"><span style="font-family: Times New Roman;">有一张表如下,用<span class="t_tag" onclick="tagshow(event)">SQL</span>求一个结果<br /></span><span style="font-family: Times New Roman;"><span style="color: #000000;">Month<br />quantity</span></span><br /><span style="color: #000000;"><span style="font-family: 宋体;">一月 </span><span style="font-family: Times New Roman;">100</span></span><br /><span style="color: #000000;"><span style="font-family: 宋体;">二月 </span><span style="font-family: Times New Roman;">200</span></span><br /><span style="color: #000000;"><span style="font-family: 宋体;">三月 </span><span style="font-family: Times New Roman;">230</span></span><br /><span style="color: #000000;"><span style="font-family: 宋体;">四月 </span><span style="font-family: Times New Roman;">340</span></span><br /><span style="color: #000000;"><span style="font-family: 宋体;">五月 </span><span style="font-family: Times New Roman;">200</span></span><br /><span style="color: #000000;"><span style="font-family: 宋体;">六月 </span><span style="font-family: Times New Roman;">120</span></span><br /><span style="color: #000000;"></span><br /><span style="font-family: Times New Roman;"><span style="color: #000000;"><br /></span></span><br /><span style="font-family: Times New Roman;"><span style="color: #000000;">SQL结果:</span></span><br /><span style="font-family: Times New Roman;"><span style="color: #000000;">month quantity</span></span><br /><span style="font-family: Times New Roman;"><span style="color: #000000;">一月 100</span></span><br /><span style="font-family: Times New Roman;"><span style="color: #000000;">二月 300</span></span><br /><span style="font-family: Times New Roman;"><span style="color: #000000;">三月 530</span></span><br /><span style="font-family: Times New Roman;"><span style="color: #000000;">四月 870</span></span><br /><span style="font-family: Times New Roman;"><span style="color: #000000;">五月 1070</span></span><br /><span style="font-family: Times New Roman;"><span style="color: #000000;">六月 1190</span></span><br /><span style="font-family: Times New Roman;"><span style="color: #000000;"><br /></span></span><br /><span style="font-family: Times New Roman;"><span style="color: #000000;">也就是算每个月从1月到当月的累计,这个SQL怎么写,就高人指点</span></span></div>
<p>
</p>