×ðÁú¿­Ê±¹ÙÍøµÇ¼

sqlplusÏÂÁîµÄÓ÷¨

ÕªÒª£ºsqlplus ÊÇÒ»ÖÖ oracle Êý¾Ý¿â½»»¥Ê½¹¤¾ß£¬ÓÃÓÚÅþÁ¬Êý¾Ý¿â²¢Ö´ÐÐ sql Óï¾ä¡ £¿Éͨ¹ýÏÂÁîÐÐÆô¶¯£¬ÏÂÁî½á¹¹°üÀ¨ sql Óï¾ä¡¢·ÖºÅºÍ»»Ðзû¡£»ù±¾ÏÂÁconnect£ºÅþÁ¬Êý¾Ý¿â¡£disconnect£º¶Ï¿ªÅþÁ¬¡£select£ºÅÌÎÊÊý¾Ý¡£update£º¸üÐÂÊý¾Ý¡£insert£º²åÈëÊý¾Ý¡£delete£ºÉ¾³ýÊý¾Ý¡£

SQLPlus ÏÂÁîÓ÷¨

SQLPlus ÊÇ Oracle Êý¾Ý¿âÖÎÀíϵͳÌṩµÄ½»»¥Ê½¹¤¾ß£¬ÓÃÓÚÅþÁ¬µ½Êý¾Ý¿â²¢Ö´ÐÐ SQL Óï¾ä¡£

Æô¶¯ SQLPlus

·­¿ªÏÂÁîÐлòÖն˲¢¼üÈëÒÔÏÂÏÂÁ

sqlplus username/password[@database]

µÇ¼ºó¸´ÖÆ

username£ºÊý¾Ý¿âÓû§Ãû

password£ºÊý¾Ý¿âÃÜÂë

@database£º¿ÉÑ¡²ÎÊý£¬Ö¸¶¨ÒªÅþÁ¬µÄÊý¾Ý¿âʵÀý

SQLPlus ÏÂÁî½á¹¹

SQLPlus ÏÂÁîÒ»Ñùƽ³£ÓÉÒÔϲ¿·Ö×é³É£º

SQL Óï¾ä£ºÓÃÓÚÖ´ÐÐÅÌÎÊ¡¢¸üС¢²åÈëºÍɾ³ý²Ù×÷¡£

·ÖºÅ (;)£ºÖÕÖ¹ SQL Óï¾ä¡£

»»Ðзû£ºÖ´ÐÐ SQL Óï¾ä¡£

»ù±¾ÏÂÁî

CONNECT£ºÅþÁ¬µ½Êý¾Ý¿â¡£

DISCONNECT£º¶Ï¿ªÓëÊý¾Ý¿âµÄÅþÁ¬¡£

SELECT£ºÅÌÎÊÊý¾Ý¡£

UPDATE£º¸üÐÂÊý¾Ý¡£

INSERT£º²åÈëÊý¾Ý¡£

DELETE£ºÉ¾³ýÊý¾Ý¡£

ÆäËû³£¼ûÏÂÁî

SHOW USER£ºÏÔʾĿ½ñÓû§¡£

DESC table_name£ºÐÎò±í½á¹¹¡£

SET LINESIZE value£ºÉèÖÃÊä³öÐеÄ×î´ó¿í¶È¡£

SET PAGESIZE value£ºÉèÖÃÊä³öÒ³ÃæµÄ×î´óÐÐÊý¡£

SPOOL file.txt£º½«Êä³öÖض¨Ïòµ½Îļþ¡£

EXIT£ÎÂ˳ö SQLPlus¡£

ʾÀý

ÒÔÏÂʾÀýչʾÁËÔõÑùʹÓà SQLPlus Ö´Ðлù±¾²Ù×÷£º

ÅþÁ¬µ½Êý¾Ý¿â

SQL> CONNECT user1/password@orcl

µÇ¼ºó¸´ÖÆ

ÅÌÎÊÊý¾Ý

SQL> SELECT * FROM employees;

µÇ¼ºó¸´ÖÆ

¸üÐÂÊý¾Ý

SQL> UPDATE employees SET salary = salary * 1.10
WHERE department_id = 10;

µÇ¼ºó¸´ÖÆ

¶Ï¿ªÓëÊý¾Ý¿âµÄÅþÁ¬

SQL> DISCONNECT

µÇ¼ºó¸´ÖÆ

×¢ÖØ£º

SQLPlus ÏÂÁî²»Çø·Ö¾Þϸд¡£

SQL Óï¾ä±ØÐèÒԷֺŠ(;) ×îºó²Å»ªÖ´ÐС£

SQLPlus ÌṩÁËÒ»¸öÏÂÁîÐнçÃ棬ÆäÖÐ SQL> ÊÇÌáÐÑ·û¡£

ÒÔÉϾÍÊÇsqlplusÏÂÁîµÄÓ÷¨µÄÏêϸÄÚÈÝ£¬¸ü¶àÇë¹Ø×¢±¾ÍøÄÚÆäËüÏà¹ØÎÄÕ£¡

ÃâÔð˵Ã÷£ºÒÔÉÏչʾÄÚÈÝȪԴÓÚÏàÖúýÌå¡¢ÆóÒµ»ú¹¹¡¢ÍøÓÑÌṩ»òÍøÂçÍøÂçÕûÀí£¬°æȨÕùÒéÓë±¾Õ¾Î޹أ¬ÎÄÕÂÉæ¼°¿´·¨Óë¿´·¨²»´ú±í×ðÁú¿­Ê±¹ÙÍøµÇ¼ÂËÓÍ»úÍø¹Ù·½Ì¬¶È£¬Çë¶ÁÕß½ö×ö²Î¿¼¡£±¾ÎĽӴýתÔØ£¬×ªÔØÇë˵Ã÷À´ÓÉ¡£ÈôÄúÒÔΪ±¾ÎÄÇÖÕ¼ÁËÄúµÄ°æȨÐÅÏ¢£¬»òÄú·¢Ã÷¸ÃÄÚÈÝÓÐÈκÎÉæ¼°ÓÐÎ¥¹«µÂ¡¢Ã°·¸Ö´·¨µÈÎ¥·¨ÐÅÏ¢£¬ÇëÄúÁ¬Ã¦ÁªÏµ×ðÁú¿­Ê±¹ÙÍøµÇ¼ʵʱÐÞÕý»òɾ³ý¡£

Ïà¹ØÐÂÎÅ

ÁªÏµ×ðÁú¿­Ê±¹ÙÍøµÇ¼

18523999891

¿É΢ÐÅÔÚÏß×Éѯ

ÊÂÇéʱ¼ä£ºÖÜÒ»ÖÁÖÜÎ壬9:30-18:30£¬½ÚãåÈÕÐÝÏ¢

QR code
ÍøÕ¾µØͼ