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

PL SQLÖи´ÖƳöµÄÖÐÎÄÂÒÂë

֮ǰʹÓÃPLSQL£¬¶¼ÊÇÒÔдÈëÄÚÈÝΪÖ÷£¬Ð´ÈëÖÐÎÄÄÚÈÝżÓÐÂÒÂ룬µ«ÊÇÖ»ÔÚÏÔʾÉϲ¢Î´Ó°Ïì´æÈ¡£¬ËùÒÔûÓÐÔÚÒâ¡£
½ñÌìÔÚÐÞ¸ÄÒ»¸öÊÓͼʱ£¬ÐèÒª½«ÐÞ¸ÄÄÚÈݼǼÏÂÀ´£¬so,Ïëд¸öÐ޸ļǼ£¬¾Í°ÑÊÓͼÄÚÈÝ¿½±´Á˳öÏÖ£¬·¢ÏÖ¿½±´³öÏÖµÄÖÐÎÄÄÚÈݳöÏÖÂÒÂë¡£
²¢Î´ÍêÈ«ÔÚÒ⣬ÒÔΪֻҪԭÑù·Å»Øplsql¾Í»áºÃµÄ£¬µ«ÊDZ£´æÔÙÈ¡³ö·Åµ½plsqlÖз¢ÏÖÈÔÈ»ÊÇÂÒÂë¡£¡£¡£
ËùÒԾͲé×ÊÁÏÕÒµ½Ò»¸öÁÙʱ½â¾ö·½·¨£¬·ÖÏí¸ø´ó¼Ò£º
 ÔÚÊäÈë·¨ÉèÖÃÖУ¬É¾³ýÓ¢ÎĵÄÃÀʽ¼üÅÌģʽ£¬Ìí¼ÓÖÐÎļüÅÌģʽ²¢ÇÒÉèÖÃΪĬÈÏÖµ¾ÍokÁË£¡


Ïà¹ØÎĵµ£º

sqlÓïÑÔÖеÄcase when £¨À´×ÔÎÒ×ð¾´µÄһλÀÏʦСF£©

sqlÓïÑÔÖÐÓÐûÓÐÀàËÆCÓïÑÔÖеÄswitch caseµÄÓï¾ä£¿£¿
  ûÓÐ,ÓÃcase   when   À´´úÌæ¾ÍÐÐÁË.  
      
  ÀýÈç,ÏÂÃæµÄÓï¾äÏÔʾÖÐÎÄÄêÔ  
   
  select   getdate()   as   È ......

³£ÓÃsqlÓï¾ä

1.ÏÞÖÆ·µ»Ø¼Ç¼µÄÐÐÊý£¨4-10ÐУ©
select rownum,c1 from t144 where rownum<10
minus
select rownum,c1 from t144 where rownum<5
2.ÅúÁ¿²åÈë
insert into tablename(select * from othertable)
»ò
insert into (column1,column2,,,,,,,)tablename(select column1,column2,,,,,,,from othertable)
3,·Ö×éº¯Ê ......

JAVAͨ¹ýODBCÁ´½ÓSQL SERVER

/**
 * @author ºýÍ¿¹í
 * ÔÚ½¨Á¢Á¬½Ó֮ǰÐèҪһЩ׼±¸¹¤×÷£º
 * ÔÚ¿ØÖÆÃæ°åÉÏͨ¹ý“¹ÜÀí¹¤¾ß”µÄ“Êý¾ÝÔ´(ODBC)”´ò¿ª“ODBCÊý¾ÝÔ´¹ÜÀíÆ÷”¶Ô»°¿ò£¬
 * µ¥»÷“ϵͳDSN”Ñ¡Ï£¬È»ºóµ¥»÷“Ìí¼Ó”°´Å¥£¬µÃµ½“´´½¨Êý¾ÝÔ´”¶Ô»°¿ò£¬
......

¸ømysqlÌí¼ÓÒ»¸ö¹ÜÀíÔ±µÄSQLÓï¾ä

insert into mysql.user
SELECT '%', 'admin', PASSWORD('admin'), Select_priv, Insert_priv, Update_priv,
 Delete_priv, Create_priv, Drop_priv, Reload_priv,
 Shutdown_priv,  Process_priv, File_priv, Grant_priv, References_priv,
 Index_priv, Alter_priv, Show_db_priv, Super_priv, ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ