DB2 SQL ¾«Òª £¨³ÖÐø¸üÐÂÖÐ.......£©
----start
·²ÊÇÖªµÀÊý¾Ý¿âµÄÈ˶¼ÖªµÀSQL£¬·²ÊǶÔSQLÓÐÒ»µãÁ˽âµÄÈ˶¼¾õµÃSQLºÜ¼òµ¥£¬·²ÊÇÓÐÕâÖָоõµÄÈ˶¼ÊÇSQLµÃ³õ¼¶Óû§£¬ÒòΪËûѧ»áÁËÔö²éɾ¸Ä¾ÍÒÔΪÕâ¾ÍÊÇSQLµÄÈ«²¿¡£Ä¿Ç°µÄ´ó²¿·ÖÓ¦ÓÃÈí¼þ¶¼ÊÇÒÔÊý¾Ý¿âΪÖÐÐÄ£¬Ëæ×ÅÈí¼þµÄÔËÐУ¬Êý¾ÝÁ¿»áÔ½À´Ô½´ó¡£ÈçºÎÓüò½à¡¢¸ßЧµÄSQLÓï¾ä²Ù×÷Êý¾ÝÏÔµÃÔ½À´Ô½ÖØÒª¡£±¾ÏµÁÐÎÄÕ½«¸ø´ó¼Ò½éÉܳ£ÓõÄһЩSQL¼¼ÇÉ¡££¨×¢Ò⣺ÕâЩ¼¼ÇÉÖ»ÊÊÓÃÓÚDB2£©
Ò»µãÄã²»Ò»¶¨ÖªµÀµÄС֪ʶ
DB2 INSERT Óï¾ä
DB2 ÖÐɾ³ýÊý¾Ý
Ëæ»ú²éѯÈô¸ÉÌõ¼Ç¼
IN Óë DISTINCT
¾¡Á¿±ÜÃâÔÚSQLÓï¾äÖÐʹÓÃOR
¾¡Á¿±ÜÃâÔÚSQLÓï¾äµÄWHERE×Ó¾äÖÐʹÓú¯Êý
¾¡Á¿±ÜÃâÔÚSQLÓï¾äÖÐʹÓÃLIKE
Ö¸¶¨¸ôÀ뼶±ð
¹ØÓÚ from
DB2 ·ÖÒ³²éѯ
½«NULLֵת»¯ÎªÆäËûÖµ
SQLÖеķÖÖ§Åжϣ¨CASEÓï¾äµÄʹÓã©
¶¨ÒåÁÙʱ¼¯ºÏ£¨VALUESÓï¾äµÄʹÓã©
¹«¹²±í±í´ïʽ£¨WITHÓï¾äµÄʹÓã©
Êý¾ÝÀàÐÍת»»
¸ü¶à¼òµ¥¶øʵÓÃµÄ DB2 SQL Óï¾ä
----ÉùÃ÷£º×ªÔØÇë×¢Ã÷³ö´¦¡£
----last update at 2009.10.13
----write by wave at 2009.9.23
----end
Ïà¹ØÎĵµ£º
ÔÚʹÓÃODP.NET½øÐÐOracle±à³Ìʱ£¬ÓÐʱºòSQLÓï¾ä·Ç³£¸´ÔÓ£¬ÐèÒª²ÉÓö¯Ì¬¹¹Ôì²éѯÓï¾äµÄÇé¿ö£¬ÓÐÁ½ÖÖ·½·¨¿ÉÒÔ¹¹Ô춯̬µÄSQLÓï¾ä£¬²¢Ö´Ðзµ»Ø½á¹û¼¯¡£
1¡¢ÔÚÊý¾Ý·ÃÎʲ㹹ÔìSQLÓï¾ä
ÀýÈçÏÂÃæµÄÓï¾ä£¬½«¹¹ÔìÍêÕûµÄSQLÓï¾ä¸³Öµ¸øCommandText£¬ÔÙ´«µÝµ½Êý¾Ý¿â½øÐÐÖ´ÐУ¬·µ»Ø½á¹û¼¯¡£
loadCommand.CommandType = Com ......
BUILTIN\Administrators
-- Õâ¸öÊÇAdmin×éµÄȨÏÞ,ĬÈÏÇé¿öϱ¾µØAdmin¶¼Á¥ÊôÓÚÕâ¸ö×é,¾ßÓбȽϴóµÄȨÏÞ,
-- ×÷ΪWindows¼¯³ÉµÇ¼,Èç¹ûʹÓõÄÊǹÜÀíÔ±,¾Í»áʹÓõ½Ëü,
HC811\ASPNET
-- Õâ¸öÊÇASPNETÓ¦ÓõķÃÎÊÕʺÅ×é,
HC811\SQLServer2005MSFTEUser$HC811$MSSQLSERVER
-- Õâ¸öÊÇÈ«ÎÄË÷ÒýµÄ·ÃÎÊÕʺ ......
±¾ÏµÁÐÎÄÕµ¼º½
[Oracle]¸ßЧµÄPL/SQL³ÌÐòÉè¼Æ(Ò»)--αÁÐROWNUMʹÓü¼ÇÉ
[Oracle]¸ßЧµÄPL/SQL³ÌÐòÉè¼Æ(¶þ)--±êÁ¿×Ó²éѯ
[Oracle]¸ßЧµÄPL/SQL³ÌÐòÉè¼Æ(Èý)--PackageµÄÓŵã
[Oracle]¸ßЧµÄPL/SQL³ÌÐòÉè¼Æ(ËÄ)--ÅúÁ¿´¦Àí
[Oracle]¸ßЧµÄPL/SQL³ÌÐòÉè¼Æ(Îå)--µ÷Óô洢¹ý³Ì·µ»Ø½á¹û¼¯
[Oracle]¸ßЧµÄPL/SQL³ÌÐòÉè¼Æ(Áù)- ......
±¾ÏµÁÐÎÄÕµ¼º½
[Oracle]¸ßЧµÄPL/SQL³ÌÐòÉè¼Æ(Ò»)--αÁÐROWNUMʹÓü¼ÇÉ
[Oracle]¸ßЧµÄPL/SQL³ÌÐòÉè¼Æ(¶þ)--±êÁ¿×Ó²éѯ
[Oracle]¸ßЧµÄPL/SQL³ÌÐòÉè¼Æ(Èý)--PackageµÄÓŵã
[Oracle]¸ßЧµÄPL/SQL³ÌÐòÉè¼Æ(ËÄ)--ÅúÁ¿´¦Àí
[Oracle]¸ßЧµÄPL/SQL³ÌÐòÉè¼Æ(Îå)--µ÷Óô洢¹ý³Ì·µ»Ø½á¹û¼¯
[Oracle]¸ßЧµÄPL/SQL³ÌÐòÉè¼Æ(Áù)- ......