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

SQL ×Ö·û´®½ØȡʾÀý

SELECT LEFT(RTRIM('20080927p1058'),LEN('20080927p1058')-2)
 
SELECT SUBSTRING('20080927p1058',1,LEN('20080927p1058')-2)
.csharpcode, .csharpcode pre
{
font-size: small;
color: black;
font-family: consolas, "Courier New", courier, monospace;
background-color: #ffffff;
/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt
{
background-color: #f4f4f4;
width: 100%;
margin: 0em;
}
.csharpcode .lnum { color: #606060; }


Ïà¹ØÎĵµ£º

Êý¾ÝÅúÁ¿µ¼ÈëÔ¶³ÌSQL·þÎñÆ÷µÄÇ×Éíʵ¼ù

¡¡¡¡Ä¿µÄ£º½«Êý¾ÝÅúÁ¿µ¼ÈëÔ¶³Ì·þÎñÆ÷
¡¡¡¡»·¾³£ºSQLÈí¼þ£¬EXCELÈí¼þ£¬VS2005Èí¼þ£¬±¾µØÁ½¸ö»úÆ÷É϶¼ÓÐSQLÊý¾Ý¿â£¬¶øÇÒÊý¾Ý´æ·ÅÔÚÆäÖÐÒ»¸ö±í¡£
¡¡¡¡²Ù×÷ʵ¼ù
¡¡¡¡1¡¢ÓÃÔ¶³ÌÊý¾Ý¿âµÄip¡¢Óû§Ãû¡¢ÃÜÂëÔÚ±¾µØµÇ¼£»
¡¡¡¡2¡¢½á¹û£¬ÆäÖÐÒ»¸ö»úÆ÷ÄܵǼ£¬Ò»¸ö²»ÄܵǼ£¨ÒÔϲÙ×÷ÔڿɵǼµÄ»úÆ÷ÉÏÍê³É£©£»
¡¡¡¡3¡¢µÚÒ»´ÎÎÒÏëͨ ......

sql group by Óë havingµÄÓ÷¨

1. GROUP BY ÊÇ·Ö×é²éѯ, Ò»°ã GROUP BY ÊǺ;ۺϺ¯ÊýÅäºÏʹÓÃ
group by ÓÐÒ»¸öÔ­Ôò,¾ÍÊÇ select ºóÃæµÄËùÓÐÁÐÖÐ,ûÓÐʹÓþۺϺ¯ÊýµÄÁÐ,±ØÐë³öÏÖÔÚ group by ºóÃ棨ÖØÒª£©
ÀýÈç,ÓÐÈçÏÂÊý¾Ý¿â±í£º
A    B
1    abc
1    bcd
1    asdfg
 Èç¹ûÓÐÈ ......

ÐÞ¸ÄSQL 2005Êý¾Ý¿âĬÈϲ»Çø·Ö´óСд

´´½¨µÄÊý¾Ý¿âÖÐÇø·Ö´óСд
create database test  COLLATE  Chinese_PRC_CS_AS  
Êý¾Ý¿âÖÐÇø·Ö´óСд
alter database test  COLLATE  Chinese_PRC_CS_AS 
»Ö¸´Ä¬ÈϵIJ»Çø·Ö´óСд
alter database test  COLLATE  Chinese_PRC_CI_AS ......

Ôõô´Óoracleͨ¹ýodbc ºÍsqlµÃµ½mysql

 oracleµÄodbcÍø¹Ø£¨gateway£©¼¸ºõÌṩһ¸öÎÞÏßµÄÊý¾ÝÕûºÏƽ̨£¬ÔÚoracleºÍÆäËüRDBMSÖ®¼ä£¬ÎÒÔÚÕâ²»Ïë˵ËüµÄ£¬²Ù×÷£¬ÏÞÖÆÒÔ¼°Ïà¹ØÐÔ£¬Ëü½â¾öÁËÒ»¸öСÎÊÌ⣬°ÑËü½¨Á¢ÆðÀ´ÄãÄÜ£¬ÀýÈ磬´´½¨Ò»¸ö database link ÔÚoracle ºÍoracleÖ®¼ä£¬±Ï¾¹£¬ÕâÑù²»ÊǺܺÃô£¬ÀýÈçÄãÄÜÔËÐÐÏÂÃæµÄsqlÓï¾ä£¬
select o.col1, m.col1 from or ......

Êý¾Ý²É¼¯Öг£ÓõÄSQLÓï¾ä¼°¼¼ÇÉ

Êý¾Ý²É¼¯Öг£ÓõÄSQLÓï¾ä
   ÏàͬµÄSQLÓï¾äÔËÓõ½²»Í¬Êý¾Ý¿âÖлáÓÐÂÔ΢µÄ²î±ð£¬¶Ô×Ö·û±äÁ¿µÄÒªÇó£¬Ïà¹Øº¯ÊýµÄ±ä»¯£¬ÒÔ¼°Óï·¨¹æÔòµÄ²»Í¬µÈµÈ£¬ÀýÈ磺oracleÊý¾Ý¿âÖжÔ×Ö¶ÎÃüÃû±ðÃûʱ²»ÐèÒªas ×Ö·û£¬Ã»ÓÐmonth()£¬year£¨£©µÈʱ¼äº¯ÊýµÈµÈ£¬accessÊý¾Ý¿âÖÐÔÚʹÓÃinner joinÖ´ÐÐÄÚ²¿ÁªºÏʱÌõ¼þÐèÓ㨣©£¬µ±È»»¹Óкܶ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ