SQLÓï¾ä OR ´æ´¢¹ý³Ì£¿ - .NET¼¼Êõ / C#
Ö´ÐÐÊý¾Ý¿â²Ù×÷ʱ£¬Ö±½ÓÓÃSQL Óï¾äºÃһЩ »¹ÊÇÓô洢¹ý³Ì¸ü¼ÑÄØ£¿
¸÷ÊãÆð¼û
Õâ¸öµÄ¾ßÌåÎÊÌâ¾ßÌå·ÖÎö
¼òµ¥µÄselect ¡¢updateºÍinsertµ±È»sql½â¾öÁË
¸´ÔӵķÅÔÚsql·þÎñ¶ËÓ¦¸ÃºÃµã
Â¥Ö÷Çë²ÎÔÄ
http://msdn.microsoft.com/zh-cn/library/ms973918(v=MSDN.10).aspx
ÄÜÓÃsqlÓï¾äʵÏֵIJ»ÒªÓô洢¹ý³Ì£¬¸´ÔӵŦÄܺÍÂß¼¹ØϵÓô洢¹ý³Ì
·ÀÖ¹sql×¢ÈëÊý¾Ý²ÎÊý»¯
»ù´¡Ôöɾ¸Ä²éÓÃSQLÓï¾ä£¬
¶ÔÓÚ¸´ÔÓÒµÎñ£¬Ê¹Óô洢¹ý³Ì£¬¶Ô¸´ÔÓ²éѯҲ¿ÉÒÔʹÓÃÊÓͼ
ÓÅÐãÓë·ÇÓÅÐãÖ®·Ö
´æ´¢¹ý³Ì±È½ÏºÃ£¬ÒòΪ´æ´¢¹ý³ÌÊÇÔ¤ÏȱàÒëºÃµÄ£¬Ö´ÐÐËٶȸü¿ì£¬¶øÇÒ¸ü°²È«£¬¿ÉÒÔÓÐЧµÄ·ÀÖ¹sql×¢Èë
×îºÃ»¹ÊÇʹÓô洢¹ý³ÌÕâÑù¿ÉÒÔ£¬ÕâÑù×öµÄϵͳÒÆÖ²ÐÔ»¹ÊDZȽϺõġ£
ʹÓô洢¹ý³ÌµÄÓŵ㻹ÊDZȽ϶àµÄ£¬·ÀÖ¹sql×¢È룬¼õÇáÁË·þÎñµÄ¸ºµ£µÈ¡£
¸Ã˵µÄÂ¥É϶¼ËµÁË....
¶¥ÉÏÈ¥£¬ËûÃǶ¼ËµµÄÓеÀÀí¡¡
¸öÈËÒ²ÕâôÈÏΪ¡£
¸´ÔÓ µ÷Óô洢¹ý³Ì
¼òµ¥ Ö±½ÓÓÃsqlÓï¾ä½øÐвÙ×÷
´Ó¼ò£¬Ò²·½±ãÐÞ¸Ä
¾ßÌåÎÊÌâ¾ßÌå·ÖÎö ÎÒ»¹ÊǾõµÃsqlÓï¾ä¸üºÃÓÃ
Õâ¸öÒª¿´¾ßÌåµÄÇé¿öÁË
´æ´¢¹ý³ÌÏûºÄµÄÊÇ·þÎñÆ÷×ÊÔ´£¬ÎÒÒ»°ãϲ»¶ÓÃsql°ÑÊý¾Ý´Ó·þÎñ¶ËÈ¡¹ýÀ´ÔÚ¿Í»§¶Ë½øÐи´ÔÓÂß¼´¦Àí£¬±Ï¾¹·þÎñÆ÷»¹ÊÇÖ´Ðмòµ¥µÄselect¸üºÃ£¬ÕâÑùÄܹ»¸üºÃ·¢»Ó¿Í»§¶ËµÄÔËËãÄÜÁ¦¡£
ËùÒÔÎÒ¾õµÃÈç¹ûûÓбØÒª£¬×îºÃ»¹ÊDz»ÒªÓô洢¹ý³Ì¡£
À´Ñ§Ï°Ñ§Ï°£¡
ÓÐÀí
Ïà¹ØÎÊ´ð£º
ÏÖÔÚÓÐÁ½ÕÅ±í£ºÎÄÕÂÖ÷±íA(articleId,articleTitle)£¬ÎÄÕÂÆÀÂÛ±íB(commentId,articleId,commentTitle)
ÏÖÔÚÎÒÏëʵÏÖÕâÑùµÄ¹¦ÄÜ£ºÁгöÎÄÕÂÁÐ±í£¬ÆäÖÐÿƪÎÄÕ±êÌâÏÂÃæÁгö´ËÎÄÕµÄÇ°2¸öÎÄÕÂÆÀÂÛ£¬ÇëÎÊsqlÓï¾äÔõôд°¡ ......
sqlµÄÈí¼þÔÚÄÄÀï¿ÉÒÔÏ°¡£¡ÔÚÍøÉÏÕÒÁËÂù¶à¶¼Óò»ÁË°¡
Ëæ±ã¸ãÒ»D°æ°É£¬
ѸÀ×µÚÒ»¸ö¾Í¿ÉÒÔÓÃ
2000,2005¶¼ÕâÑù
http://119.147.41.16/down?cid=0698C2D64D7D637D90A6D2482298E6717D4F15CD&t=2&fmt=-1 ......
tab1 ×Ö¶Î:billdate,goodsid,incount,inmoney,outcount,outmoney,endprice,endcount,endamt
tab2 ×Ö¶Î:goodsid,goodskind£¨ÉÌÆ·ÀàÐÍ£©
tab3 ×Ö¶Î:goodskind£¨ÉÌÆ·ÀàÐÍ£©,kindname
½á¹û£º
µÃµ½ÉÌÆ·ÀàÐÍÔÚÒ»¶Îʱ¼ä ......
¸÷λºÃ£¬ÎÒ¸Õ°ÑÒ»¸öASPÍøÕ¾ÉèÖúÃÁË£¬Ò²ÄÜÕý³£·ÃÎÊ¡£µ«ÊÇÔÚÎÒ±¾»úÉϲ»ÄÜ´ò¿ªadmin\login.asp,ËùÒÔÎÞ·¨ÊµÏÖºǫ́¹ÜÀí¡££¨´íÎóÌáʾÎÞ·¨ÕÒµ½ÍøÒ³£¬´úÂë404£¬ÎҵIJÙ×÷ϵͳÊÇwin2000 server)
µ«ÊÇÆæ¹ÖµÄÊÇÔÚ¾ÖÓòÍøµÄÆäËû» ......
A±í ÓÐÁ½¸ö×Ö¶Î
id ΨһÊý×ÖÓò
InfoTxt text ÀàÐÍ
ÎÒÏÖÔÚÒª°Ñ id ²»ÊÇ14 µÄËùÓÐ InfoTxt×ֶΠÎı¾ºóÃæ ¶¼¼ÓÉÏ 'aaa'
°´ÏÂÃæÖ´ÐÐÏÂÀ´ Ö»Óбí×îºóÒ»ÐмÓÉÏÁË 'aaa' ......