Oracle´æ´¢¹ý³Ìת³ÉSqlserver´æ´¢¹ý³Ì
Oracle´æ´¢¹ý³Ìת³ÉSqlserver´æ´¢¹ý³Ì
1.ÈÕÆÚת»»
Oracle£º TO_NUMBER(TO_CHAR(SYSDATE, 'YYYYMMDD'))
SqlServer£ºCAST(CONVERT(CHAR(8),GETDATE(), 112) AS INT)
×¢£ºÆäÖБYYYYMMDD’¸ñʽ ¶ÔÓ¦112
2.ROWIDת»»
Oracle£º ROWID
SqlServer: PRIMARY KEY(±íÖ÷¼ü)
3.ROWNUM
Oracle£º ROWNUM = 1
SqlServer£º Top 1
×¢£ºÒ»°ãSelectÖеÄÕâ¸ö¿ÉÒÔÖ±½ÓÌæ»»£¬µ«ÊÇÔÚUpdateÖоͱȽÏÄÑÁË£¬ÈçÏ£º
Oracle£º UPDATE ITEM_MST SET
HISD_FLAG = 1
WHERE
ROWID = C2.ROWID;
Sqlserver : UPDATE ITEM_MST SET
HISD_FLAG = 1 --AND ROWNUM = 1 ---KEY
WHERE ITEM_CD IN --=
(SELECT TOP 1 ITEM_CD from ITEM_MST WHERE SALES_NO = @C1_ITEM_NAME )
Ò²¾ÍÊÇ˵£¬¿ÉÒÔÀûÓøÃÐÐÖÐÆäËûµÄÒÑÖªÐÅÏ¢»ñÈ¡¸ÃÏîÊý¾Ý¡£
¡£¡£¡£¡£¡£¡£
£¨Î´Í꣬´ýÐø¡££©
Ïà¹ØÎĵµ£º
1¡¢µ÷ÕûĬÈϵݲȫÉèÖÃ
1.1¡¢Ä¬ÈϵÄÓû§
²é¿´Êý¾Ý¿âµÄÓû§ºÍ״̬£¬¿ÉÒÔ²éѯDBA_USERSÊÓͼ¡£
?[Copy to clipboard]View Code SQL
SQL> select username,account_status from dba_users;
1.2¡¢PUBLICȨÏÞ
OracleÖдæÔÚÒ»¸öÃûΪPUBLICµÄαÓû§¡£Ö»ÒªÓÃPUBLICÊÚÓèij¸öȨÏÞ£¬ÄÇôËùÓÐÓû§¶¼»á±»ÊÚÓèÕâ¸öȨÏÞ¡£
?[Copy ......
1¡¢±¸·Ý¹¤¾ß
Ö±½ÓʹÓòÙ×÷ϵͳʵÓóÌÐòcopy¡¢cp¾Í¿ÉÒÔ½øÐб¸·Ý²Ù×÷¡£µ«£¬OracleÇ¿ÁÒ½¨ÒéʹÓÃRecovery Manager£¨»Ö¸´¹ÜÀíÆ÷£¬¼òдRMAN£©¡£
RMANÄܹ»±¸·ÝÊý¾ÝÎļþ¡¢¿ØÖÆÎļþ¡¢¹éµµÈÕÖ¾ÒÔ¼°·þÎñÆ÷²ÎÊýÎļþ£¨spfile£©¡£±¸·Ý¿ÉÒÔ±»Ð´Èë´ÅÅÌ»ò´Å´ø¡£
2¡¢¸ÅÄîÓëÊõÓï
2.1¡¢È«²¿±¸·ÝÓ벿·Ö±¸·Ý
È«²¿±¸·Ý£¨whole backup£©ÊÇËùÓÐÊ ......
ÔÎÄ:ORA-00600 internal error code, arguments: [string], [string], [string], [string], [string], [string], [string], [string]
¡¡¡¡Cause This is the generic internal error number for Oracle program exceptions. It indicates that a process has encountered a low-level, unexpected condition. Causes of t ......
֮ǰ¸ø´ó¼Ò½éÉÜÁËÔÚWIN7ÉÏOracle 10gµÄ°²×°·½·¨£¬½ÓÏÂÀ´¾Í¸Ã¸ø´ó¼Ò½éÉÜËüµÄжÔØ·½·¨ÁË¡£ºÜ¶àÈ˲»¸Ò°²×°Oracle¾ÍÊǵ£ÐÄ°²×°ºó»áжÔز»¸É¾»£¬Æäʵµ±³õÎÒÒ²ÓйýÕâ¸ö¹ËÂÇ£¬ºÇºÇ¡£µ«ºóÀ´·¢ÏÖ£¬ÆäʵжÔØÊǺÜÈÝÒ×µÄÊ¡£¾Í¼¸²½¶øÒÑ£¬²»ÐžÍÇë¿´£º
¿ÉÒÔʹÓòúÆ·×Ô´øµÄжÔع¤¾ßȥжÔØ¡£
1£® ......
1£©²»Öª´ó¼ÒÊÇ·ñϲ»¶Ê¹ÓÑNOT IN’ÕâÑùµÄ²Ù×÷£¬Èç¹ûÊÇ£¬ÄǾ¡Á¿Ê¹ÓÃ(NOT) EXISTS Ìæ´ú
2£©ÔÚº£Á¿²éѯʱ¾¡Á¿ÉÙÓøñʽת»»¡£
3£©²éѯº£Á¿Êý¾ÝÊÇ£¬¿ÉÒÔʹÓÃoptimizer['ɔptimaizə] hints£¬ÀýÈç/*+ORDERED */
¾¡Á¿ÉÙÓÃIN²Ù×÷·û£¬»ù±¾ÉÏËùÓеÄIN²Ù×÷·û¶¼¿ÉÒÔÓÃEXISTS´úÌæ¡£
²»ÓÃNOT IN²Ù×÷·û£¬¿ÉÒÔ ......