PL/SQL DeveloperʹÓü¼ÇÉ
PL/SQL DeveloperʹÓü¼ÇÉ
1¡¢PL/SQL Developer¼ÇסµÇ½ÃÜÂë
ÔÚʹÓÃPL/SQL Developerʱ£¬ÎªÁ˹¤×÷·½±ãÏ£ÍûPL/SQL Developer¼ÇסµÇ¼OracleµÄÓû§ÃûºÍÃÜÂ룻
ÉèÖ÷½·¨£ºPL/SQL Developer 7.1.2 ->tools->Preferences->Oracle->Logon History £¬ "Store history"ÊÇĬÈϹ´Ñ¡µÄ£¬¹´ÉÏ"Store with password" ¼´¿É£¬ÖØеǼÔÚÊäÈëÒ»´ÎÃÜÂëÔò¼ÇסÁË¡£
2¡¢Ö´Ðе¥ÌõSQLÓï¾ä
ÔÚʹÓÃPL/SQL DeveloperµÄSQL Windowʱ£¬°´F8¼ü£¬PL/SQL DeveloperĬÈÏÊÇÖ´Ðиô°¿ÚµÄËùÓÐSQLÓï¾ä£¬ÐèÒªÉèÖÃΪÊó±êËùÔÚµÄÄÇÌõSQLÓï¾ä£¬¼´Ö´Ðе±Ç°SQLÓï¾ä£»
ÉèÖ÷½·¨£ºPL/SQL Developer 7.1.2 -->tools->Preferences-->Window types £¬¹´ÉÏ"AutoSelect Statement" ¼´¿É¡£
3¡¢¸ñʽ»¯SQLÓï¾ä
ÔÚʹÓÃPL/SQL DeveloperµÄSQL Windowʱ£¬ÓÐʱºòÊäÈëµÄSQLÓï¾äÌ«³¤»òÌ«ÂÒ£¬Ï£ÍûÄÜÓñȽÏͨÓõÄд·¨¸ñʽ»°Ò»Ï£¬ÕâÑù¿´ÆðÀ´»áºÃ¿´Ð©£¬Ò²ºÃ·ÖÎö£»
ʹÓ÷½·¨£ºÑ¡ÖÐÐèÒª¸ñʽ»¯µÄSQLÓï¾ä£¬È»ºóµã»÷¹¤¾ßÀ¸µÄPL/SQL beautifier°´Å¥¼´¿É.
4¡¢²é¿´Ö´Ðмƻ®
ÔÚʹÓÃPL/SQL DeveloperµÄSQL Windowʱ£¬ÓÐʱºòÊäÈëµÄSQLÓï¾äÖ´ÐеÄЧÂÊ£¬·ÖÎöϱí½á¹¹£¬ÈçºÎ¿ÉÒÔÌá¸ß²éѯµÄЧÂÊ£¬¿ÉÒÔͨ¹ý²é¿´OracleÌṩµÄÖ´Ðмƻ®£»
ʹÓ÷½·¨£ºÑ¡ÖÐÐèÒª·ÖÎöµÄSQLÓï¾ä£¬È»ºóµã»÷¹¤¾ßÀ¸µÄExplain plan°´Å¥£¨¼´Ö´Ðмƻ®£©£¬»òÕßÖ±½Ó°´F5¼´¿É¡£
5¡¢µ÷ÊÔ´æ´¢¹ý³Ì
ÔÚʹÓÃPL/SQL Developer²Ù×÷Oracleʱ£¬ÓÐʱºòµ÷ÓÃijЩ´æ´¢¹ý³Ì£¬»òÕßµ÷ÊÔ´æ´¢¹ý³Ì£»
µ÷Óô洢¹ý³ÌµÄ·½·¨£ºÊ×ÏÈ£¬ÔÚPL/SQL Developer×ó±ßµÄBrowserÖÐÑ¡ÔñProcedures£¬²éÕÒÐèÒªµ÷ÓõĴ洢¹ý³Ì£»È»ºó£¬Ñ¡Öе÷ÊԵĴ洢¹ý³Ì£¬µã»÷ÓÒ¼ü£¬Ñ¡ÔñTest£¬ÔÚµ¯³öÀ´µÄTest scrīpt´°¿ÚÖУ¬¶ÔÓÚ¶¨ÒåΪinÀàÐ͵IJÎÊý£¬ÐèÒª¸ø¸Ã²ÎÊýµÄValueÊäÈëÖµ£»×îºóµã»÷ÉÏÃæµÄÌõÊý°´Å¥£ºStart debugger »òÕß°´F9£»×îºóµã»÷£ºRUN »òÕßCtrl+R
·OracleѧϰÊֲ᣺ÐÂÊÖ³£¼û´íÎóС¼¯
ûÓÐÈË»á·ñÈÏORACLEÊÇÈ«Çò×îÓÐÓ°ÏìµÄÊý¾Ý¿â²úÆ·Ö®Ò»;²»¹ýºÃµÄ¶«Î÷Ëƺõ×ܲ»ÊÇÄÇôºÃÓÃ(³õ¿´ÆðÀ´Èç´Ë)£¬ÉõÖÁÓÐЩÎÞÇé--×Ü»á¸ølaymanÃÇÒ»¸ö¸öÎÞÇéµÄ´íÎóºÅ¡£ÏÂÃæÊÇÎÒ¸öÈ˵Ä×ܽᣬÌõÌõÓÐÓã¬Ï£ÍûÄܸø³õѧÕßÒ»µãÆôʾ¡£
¡¡¡¡¹ØÓÚ"ºÃµÄ¶«Î÷Ëƺõ×ܲ»ÊÇÄÇôºÃÓÃ(³õ¿´ÆðÀ´Èç´Ë)"µÄÒ»¸öЦ»°:ÔÚ²Î¼Ó IBM DB2 512¡¢513Åàѵǰ£¬ÔÚУ԰ÍøÉÏÏÂÔص½ÁË°²×°³ÌÐò£¬²»¹ýÈÎƾÎÒÃǼ¸¸öͬѧÑо¿¸ö°ëÌ죬Ҳ²»ÖªÄ
Ïà¹ØÎĵµ£º
ÎÒÃÇÏÈ¿´ NestedLoop ºÍ MergeJoin µÄËã·¨£¨ÒÔÏÂΪÒýÓ㬼û RicCC µÄ¡¶ ͨÍùÐÔÄÜÓÅ»¯µÄÌìÌà - µØÓü JOIN ·½·¨ËµÃ÷ ¡· ):
==================================
NestedLoop:
foreach rowA in tableA where tableA.col2=?
{
search rowsB from tableB where tab ......
¾ßÌå³ö´¦²»Ïê¡£
ÈçºÎÈÃÄãµÄSQLÔËÐеøü¿ì
---- ÈËÃÇÔÚʹÓÃSQLʱÍùÍù»áÏÝÈëÒ»¸öÎóÇø£¬¼´Ì«¹Ø×¢ÓÚËùµÃµÄ½á¹ûÊÇ·ñÕýÈ·£¬¶øºöÂÔÁ˲»Í¬µÄʵÏÖ·½·¨Ö®¼ä¿ÉÄÜ´æÔÚµÄÐÔÄܲîÒ죬ÕâÖÖÐÔÄܲîÒìÔÚ´óÐ͵ĻòÊǸ´ÔÓµÄÊý¾Ý¿â»·¾³ÖУ¨ÈçÁª»úÊÂÎñ´¦ÀíOLTP»ò¾ö²ßÖ§³ÖϵͳDSS£©ÖбíÏÖµÃÓÈΪÃ÷ÏÔ¡£±ÊÕßÔÚ¹¤×÷ʵ¼ùÖз¢ÏÖ£¬²»Á¼µÄSQLÍùÍùÀ´×ÔÓÚ² ......
¹ØÓÚ±¾Îı¾ÎÄËùÃè»æµÄ¹¦Äܺͼƻ®ÊÇÏÂÒ»°æ±¾ SQL Server µÄ¿ª·¢·½Ïò¡£ËüÃDz¢·Ç±¾²úÆ·µÄ˵Ã÷Ê飬ÈçÓиü¸Ä£¬Ë¡²»ÁíÐÐ֪ͨ¡£¶ÔÓÚ×îÖÕ²úÆ·ÊÇ·ñ¾ßÓÐÕâЩ¹¦Äܲ»×öÈκÎÃ÷ʾ»ò°µÊ¾µÄ±£Ö¤¡£¶ÔÓÚijЩ¹¦ÄÜ£¬±¾ÎļÙÉè¶ÁÕßÊìϤ SQL Server 2000 ¹¦ÄܺͷþÎñ¡£Óйر³¾°ÐÅÏ¢£¬Çë·ÃÎÊSQL Server ÍøÕ¾»ò SQL Server 2000 ×ÊÔ´¹¤¾ß°ü¡£Õâ²¢²»Ê ......
»ù±¾µÄSql±àдעÒâÊÂÏî
¾¡Á¿ÉÙÓÃIN²Ù×÷·û£¬»ù±¾ÉÏËùÓеÄIN²Ù×÷·û¶¼¿ÉÒÔÓÃEXISTS´úÌæ¡£
²»ÓÃNOT IN²Ù×÷·û£¬¿ÉÒÔÓÃNOT EXISTS»òÕßÍâÁ¬½Ó+Ìæ´ú¡£
OracleÔÚÖ´ÐÐIN×Ó²éѯʱ£¬Ê×ÏÈÖ´ÐÐ×Ó²éѯ£¬½«²éѯ½á¹û·ÅÈëÁÙʱ±íÔÙÖ´ÐÐÖ÷²éѯ¡£¶øEXISTÔòÊÇÊ×Ïȼì²éÖ÷²éѯ£¬È»ºóÔËÐÐ×Ó²éѯֱµ½ÕÒµ½µÚÒ»¸öÆ¥ÅäÏî¡£NOT EXISTS±ÈNOT INЧÂÊ ......
1.select * into [±í] from OPENROWSET('MICROSOFT.JET.OLEDB.4.0','Excel 5.0;HDR=YES;DATABASE=D:\VFP\jspg\QuickEval2.5\Export\20092\dgqxps.xls',dgqxps$)
ÈôÓöµ½SQL Server ×èÖ¹Á˶Ô×é¼þ 'Ad Hoc Distributed Queries' µÄ STATEMENT'OpenRowset/OpenDatasource' µÄ·ÃÎÊ£¬ÒòΪ´Ë×é¼þÒÑ×÷Ϊ´Ë·þÎñÆ÷°²È«ÅäÖõÄÒ»²¿·Ö¶ø ......