ÇòÒ»¾äsql - .NET¼¼Êõ / ASP.NET
table A
id income
1 120
2 211
3 116
........
table sum
id total
1 120 --1
2 331 --1+2
3 447 --1+2+3
........
ÈçºÎ°´Ìì»ã×ÜÒÔÀ´µÄÊÕÈ룬sqlÔõôд
select sum(Income) from Table
where Date between StartDate and EndDate
§Ö÷±íÊö²»Çå³þ°¡¡£¡£¡£¡£¡£¡£ÉÏÃæµÄ¾ÍÊÇsumÁË£¬×Ô¼º¸ãÇå³þÁ˺ܺÃдµÄ£¬ÎÞ·ÇÊÇgroup byºÍinner joinÖ®ÀàµÄ¡£¡£¡£
1 120
2 331
3 447
Õâ¸öÊǸù¾Ýtable A Êä³öµÄsum±í
ÓαêÒ²¿ÉÒÔ£¬²»¹ýÂ¥Éϵĸü¼ò½àµã¡£
ѧϰ¡¡
¹þ¹þ£¬Ã÷°×ÁË
¶ÔÁË£¬ÄÇselect * from aÈçºÎ¸³¸ø@tÄØŶ£¡
Çë½ÌLZ
¿É²»¿ÉÒÔ¸øÎÒÉÔ΢½²Ò»ÏÂ
¡°SELECT b.id,
(SELECT SUM(a.income) from @t a
Ïà¹ØÎÊ´ð£º
function CheckOpwd(){//ÑéÖ¤Óû§Ãû
var pwd=document.all.txtOpwd;
var div1=document.getElementById("divPwd");
if (pwd.value=="")
{
......
¿ÉÄÜÒòΪ¹¤×÷µÄÔÒò ½Ó´¥Êý¾Ý¿âÕâ¿é±È½ÏÉÙ£¬Ö®Ç°¶¼ÊÇ×ö³ÌÐòÕâ¿é£¬Êý¾Ý¿âÕâ¿é¶¼ÓÐרÃŵÄÈËÀ´×ö ·Ö¹¤¶¼ºÜÃ÷ϸ ËùÒÔ¶ÔÊý¾Ý¿âÕâÒ»¿éÍêÈ«²»Á˽⡣ǰ¶Îʱ¼ä È¥ÃæÊÔÁ˼¸¼Ò¹«Ë¾ ¼¸ºõ¶¼ÊÇÔÚÊý¾Ý¿âÕâ¿é¹ÒµôµÄ Á¬¸ö¼òµ¥µÄSQ ......
ÎÒÓÃ.net¿ª·¢wapÍøÕ¾
1£¬ÎÒ´Ó¹¤¾ßÏäÀïÍÏÁËÁ½¸ölink£¬ÕâÁ½¸ölink»áÏÔʾÔÚÁ½ÐУ¬Èç¹ûÈÃÕâÁ½¸ölink´¦ÓÚͬһÐС£
2£¬ÈçºÎÏÔʾÁ½¸ö¿Ø¼þÖ®¼äµÄ¿Õ¸ñÎÊÌâ¡£
¸úwapÓйØÂ𣿲»Ì«Ã÷°×
ÓÑÇé°ï¶¥¡£¡£¡£¡£¡£¡£¡£¡£¡£¡£
¾Í ......
ÎÒ×î½ü×öÁËÒ»¸öÍøÕ¾ÊǹØÓÚ²úƷչʾµÄ ~ Õû¸öÍøվͼƬ¶¼Õ¼ÓÃÁËÒ»´ó°ë
ÕâÑùµÄ»°·ÃÎÊËٶȾͷdz£Âý ÓÐʲô°ì·¨¿ÉÒÔ½â¾öÂð£¿
Âé·³´ó¼Ò¶à¶à¸øµãÒâ¼û £¡ ÓÐʲô¾¡¹Ü˵
3Q´ó¼Ò
htmlÒ³Ãæ.
Õâ¸ö,¼ÈÈ»Ö÷Ò ......