Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

»¹Ô­SQLʧ°Ü

Êý¾Ý¿âÖ´ÐÐexec sp_renamedb 'oldname','newname'Óï¾ä£¬ÖØÃüÃûºó£¬½«Êý¾Ý¿â±¸·ÝÎļþ»¹Ô­Ê±£¬»á³öÏÖ´íÎó£¬Èçͼ
ÒòÊýÊý¾ÝÎļþÓëÊý¾Ý¿âÃû³Æ²»Ò»Ö¡£
½â¾ö·½·¨£º¿ÉÒÔÕÒµ½Êý¾ÝÎļþµÄÃû³Æ£¬½«Êý¾Ý¿â»¹Ô­Ãû³Æ¸úÊý¾Ý¿âÎļþÒ»ÖµÄÃû³Æ£¬´Ëʱ»¹Ô­³É¹¦ºó£¬ÔÙÐÞ¸ÄÊý¾Ý¿âµÄÃû³Æ¡£
×¢£ºÊý¾Ý¿âÖØÃüʱ£¬Ð轫SQL·þÎñÆ÷Í£Ö¹£¬ÖØÃüÃûºóÔÙÖØÐÂÆô¶¯


Ïà¹ØÎĵµ£º

SQL SERVER¸ü¸ÄsaÓû§

£¬SQLÓиö³¬¼¶Óû§sa£¬´ËÓû§Ä¬ÈÏÇé¿öÏ£¬ËüÖ¸Åɸø¹Ì¶¨·þÎñÆ÷½ÇÉ« sysadmin£¬²¢²»ÄܽøÐиü¸Ä¡£Ò»°ã¶®µã°²È«ÎÊÌâµÄ¼¼ÊõÈËÔ±¶¼»á°ÑÕâ¸öÃÜÂëÐ޸ĵô£¬µ«ÐÞ¸ÄÔÙ¸´ÔÓµÄÃÜÂ붼²»ÊǾø¶Ô°²È«µÄ£¬Ò»Ð©±©Á¦ÆƽâÈí¼þ£¬²ËÄñ¶¼»áÓá£
ÄÇÔõô°ìÄØ£¬×îºÃµÄ°ì·¨¾ÍÊÇɾ³ý»ò¸ÄÃû£¬ÏÂÃæÌṩ·½·¨.
ÐÞ¸ÄSAÓû§Ãû£º
Ò»£ºÔÚÆóÒµ¹ÜÀíÆ÷ÖÐÓÒ»÷£º(lo ......

ÓÃSQLÈ¡²¿·Ö¼Ç¼

´Ótablename ±íÖÐÈ¡³öµÚ n Ìõµ½µÚ m ÌõµÄ¼Ç¼
SQL SERVERµÄд·¨
SELECT TOP m-n+1 *
from tablename
WHERE (id NOT IN
(SELECT TOP n-1 id from tablename))
ÄãÕâÊÇÒ»¸ö·ÖÒ³Ëã·¨µÄ£¬ÎÒÌṩµÄ±È½Ï¼òµ¥£¬ÍøÉÏ»¹Óкܶ಻´íµÄ£¬Èç¹ûÄã¶ÔÕâ¸ö²»ÂúÒ⣬ÔÙÈ¥ÍøÉÏÕÒÕÒ ¹Ø¼ü×Ö “·ÖÒ³Ëã·¨”
ORACLEµÄ»°¸ÄһϠ......

SQL×¢ÈëÔ­ÀíÉî¶È½âÎö

¶ÔÓÚWebÓ¦ÓÃÀ´Ëµ£¬×¢Éäʽ¹¥»÷ÓÉÀ´ÒѾ㬹¥»÷·½Ê½Ò²Î廨°ËÃÅ£¬³£¼ûµÄ¹¥»÷·½Ê½ÓÐSQL×¢Éä¡¢ÃüÁî×¢ÉäÒÔ¼°Ð½ü²Å³öÏÖµÄXPath×¢ÉäµÈµÈ¡£±¾ÎĽ«ÒÔSQL×¢ÉäΪÀý£¬ÔÚÔ´Â뼶¶ÔÆä¹¥»÷Ô­Àí½øÐÐÉîÈëµÄ½²½â¡£
Ò»¡¢×¢Éäʽ¹¥»÷µÄÔ­Àí
×¢Éäʽ¹¥»÷µÄ¸ùÔ´ÔÚÓÚ£¬³ÌÐòÃüÁîºÍÓû§Êý¾Ý£¨¼´Óû§ÊäÈ룩֮¼äûÓÐ×öµ½ãþμ·ÖÃ÷¡£ÕâʹµÃ¹¥»÷ÕßÓлú»á½« ......

SQL Trigger(´¥·¢Æ÷)

´¥·¢Æ÷ÊÇÒ»ÖÖÌØÊâµÄ´æ´¢¹ý³Ì£¬ÔÚÓû§ÊÔͼ¶ÔÖ¸¶¨µÄ±íÖ´ÐÐÖ¸¶¨µÄÊý¾ÝÐÞ¸ÄÓï¾äʱ×Ô¶¯Ö´ÐС£Microsoft® SQL Server™ ÔÊÐíΪÈκθø¶¨µÄ INSERT¡¢UPDATE »ò DELETE Óï¾ä´´½¨¶à¸ö´¥·¢Æ÷¡£
1¡¢INSERT´¥·¢Æ÷£º¿ÉÒÔ¶¨ÒåÒ»¸öÎÞÂÛºÎʱÓÃINSERTÓï¾äÏò±íÖвåÈëÊý¾Ýʱ¶¼»áÖ´ÐеĴ¥·¢Æ÷¡£
       ......

WEB°²È«½â¾ö·½°¸Ò»Ö®SQL×¢Èë·À·¶

Ò»¡¢SQL×¢Èë·À·¶
ÔÚÒ»¸öWEB¶¯Ì¬Ò³ÃæÖУ¨ÀýÈçaspx»òÕßjsp£©£¬Õâ¸öÒ³ÃæÔÊÐíÓû§ÔÚÊäÈë¿òÖÐÊäÈë×Ö·û£¬Õâ¸ö×Ö·û¿ÉÒÔ±»ÒýÈëµ½Êý¾Ý¿âÖÐÈ¥½øÐвéѯ£¨ÕâÀïµÄ²éѯÊÇͨÓõÄ˵·¨£¬Êµ¼ÊÉÏ°üÀ¨ÁËÔöɾ¸Ä²é£©²Ù×÷¡£Ò»¸öºÚ¿ÍÔÚÕâ¸öÊäÈë¿òÖÐÊäÈëÁËÒ»¸ö»ûÐβéѯ×Ö·û´®£¬´Ó¶ø¸Ä±äÁËÔ­ÓеIJéѯ£¬Õâ¿ÉÒÔ±»ÓÃÀ´²åÈ룬¸Ä±ä£¬»òË𺦺ǫ́Êý¾Ý¿â¡£Ôõà ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ