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

SQL Server 2008¼¸ÏîÐÂÌØÐÔ¸ÅÊö

¼Æ»®ÓÚ2008ÄêµÚÒ»¼¾¶È·¢²¼µÄSQL Server 2008²»½ö¶ÔÔ­ÓÐÐÔÄܽøÐÐÁ˸Ľø£¬»¹Ìí¼ÓÁËÐí¶àÐÂÌØÐÔ£¬±ÈÈçÐÂÌíÁËÊý¾Ý¼¯³É¹¦ÄÜ£¬¸Ä½øÁË·ÖÎö·þÎñ£¬±¨¸æ·þÎñ£¬ÒÔ¼°Office¼¯³ÉµÈµÈ¡£
¡¡¡¡SQL Server¼¯³É·þÎñ
¡¡¡¡SSIS(SQL Server¼¯³É·þÎñ)ÊÇÒ»¸öǶÈëʽӦÓóÌÐò£¬ÓÃÓÚ¿ª·¢ºÍÖ´ÐÐETL(½âѹËõ¡¢×ª»»ºÍ¼ÓÔØ)°ü¡£SSIS´úÌæÁËSQL 2000µÄDTS¡£ÕûºÏ·þÎñ¹¦ÄܼȰüº¬ÁËʵÏÖ¼òµ¥µÄµ¼Èëµ¼³ö°üËù±ØÐèµÄWizardµ¼Ïò²å¼þ¡¢¹¤¾ßÒÔ¼°ÈÎÎñ£¬Ò²Óзdz£¸´ÔÓµÄÊý¾ÝÇåÀí¹¦ÄÜ¡£SQL Server 2008 SSISµÄ¹¦ÄÜÓкܴóµÄ¸Ä½øºÍÔöÇ¿£¬±ÈÈçËüµÄÖ´ÐгÌÐòÄܹ»¸üºÃµØ²¢ÐÐÖ´ÐС£ÔÚSSIS 2005£¬Êý¾Ý¹ÜµÀ²»ÄÜ¿çÔ½Á½¸ö´¦ÀíÆ÷¡£¶øSSIS 2008Äܹ»ÔڶദÀíÆ÷»úÆ÷ÉÏ¿çÔ½Á½¸ö´¦ÀíÆ÷ ¡£¶øÇÒËüÔÚ´¦Àí´ó¼þ°üÉÏÃæµÄÐÔÄܵõ½ÁËÌá¸ß¡£SSISÒýÇæ¸ü¼ÓÎȶ¨£¬ËøËÀÂʸüµÍ¡£
¡¡¡¡Lookup¹¦ÄÜÒ²µÃµ½Á˸Ľø¡£LookupÊÇSSISÒ»¸ö³£ÓõĻñÈ¡Ïà¹ØÐÅÏ¢µÄ¹¦ÄÜ¡£±ÈÈç´ÓCustomerID²éÕÒCustomer Name£¬»ñÈ¡Êý¾Ý¼¯¡£LookupÔÚSSISÖкܳ£¼û£¬¶øÇÒ¿ÉÒÔ´¦ÀíÉÏ°ÙÍòÐеÄÊý¾Ý¼¯£¬Òò´ËÐÔÄÜ¿ÉÄܺܲSQL 2008¶ÔLookupµÄÐÔÄÜ×÷³öºÜ´óµÄ¸Ä½ø£¬¶øÇÒÄܹ»´¦Àí²»Í¬µÄÊý¾ÝÔ´£¬°üÀ¨ ADO.NET£¬XML£¬OLEDBºÍÆäËûSSISѹËõ°ü¡£
¡¡¡¡SQL 2008¿ÉÒÔÖ´ÐÐTSQLµÄMERGEÃüÁî¡£ÓÃMERGEÃüÁֻÐèÒ»¸öÓï¾ä¾Í¿ÉÒÔ¶ÔÐнøÐÐ UPDATE¡¢INSERT»ò DELETE¡£ÏÂÃæµÄÀý×Ó¾ÍÊÇÈçºÎÓÃMERGEÃüÁîÀ´°ÑеÄInventory Item descriptions Áбí²åÈëÒÑÓеÄInventory MasterÖС£³ýÁË descriptions£¬ NewInventory±í¸ñÖл¹¼ÓÈëÁËÆäËûһЩ²¿·Ö¡£Èç¹ûûÓÐMERGEÓï¾ä£¬¾ÍÐèÒªÖ´ÐÐÁ½¸öÃüÁî²ÅÄÜÍê³É¡£µÚÒ»¸öÃüÁî²éÕÒÆ¥ÅäµÄDescriptionÈ»ºó¸üС£µÚ¶þ¸öÃüÁî²éÕÒ²»Æ¥ÅäÏîÈ»ºó²åÈë¡£ÓÐÁËMERGE£¬Ò»¸öÓï¾ä¾Í¿ÉÒÔÍê³ÉÕâÁ½¸öÈÎÎñ¡£²½ÖèÈçÏ£º


¡¡¡¡MERGE InventoryMaster AS im
¡¡¡¡USING (SELECT InventoryID, Descr from NewInventory) AS src
¡¡¡¡ON im. InventoryID = src. InventoryID
¡¡¡¡WHEN MATCHED THEN
¡¡¡¡UPDATE SET im.Descr = src.Descr
¡¡¡¡WHEN NOT MATCHED ,RAID0Êý¾Ý»Ö¸´;THEN
¡¡¡¡INSERT (InventoryID, Descr) VALUES (src. InventoryID, src.Descr);


¡¡¡¡·ÖÎö·þÎñ
¡¡¡¡SSAS(SQL Server·ÖÎö·þ


Ïà¹ØÎĵµ£º

mysqlºÍsql server

ÔÚÐÔÄÜÉÏ£¬mysqlÊÇÏ൱³öÉ«µÄ£¬×ÀÃæ¸ñʽmyisamÊý¾Ý¿âÓë´ÅÅ̷dz£µØ¼æÈݶø²»Õ¼Óùý¶àµÄcpuºÍÄڴ棬mysqlÄÚ²¿ºÜ¶àʱºò¶¼Ê¹ÓÃ64λÕûÊý´¦Àí¡£yahoo¾ÍʹÓÃmysqlºǫ́Êý¾Ý¿â¡£
µ«mysqlȱÉÙһЩ¸½¼Ó¹¦ÄÜ£¬Ã»ÓÐSqlServerÈ«Ãæ¡£
sqlserverÎȶ¨ÐÍÇ¿£¬µ«±ØÐëÔö¼Ó¶îÍ⸴ÔÓ²Ù×÷£¬´ÅÅÌ´æ´¢£¬ÄÚ´æËðºÄµÈ£¬¶ÔÓ²¼þÈí¼þÒªÇ󶼺ܸߡ£
ÕâÁ½¸öÊý ......

SQL×éºÏ²éѯ¼°ÏȺó˳Ðò¶ÔЧÂʵÄÓ°Ïì

ÔÚSQL¿ç±í×éºÏ²éѯ´æÔÚЧÂÊÎÊÌ⣬¾ÙÀý±ÈÈç
delete from media_source where movie_id in ( select media_id from media where type=2 ) and origin = 3;
ºÍ
delete from media_source where origin = 3 and movie_id in ( select media_id from media where type=2 );
µÄЧÂÊÊDz»Ò»ÑùµÄ¡£
Èôorigin=3µÄÇé¿öÏÂmedia_so ......

sql¶à±íÁªºÏ²éѯµÄÎÊÌâ

ÏÖÔÚÓöµ½Á˸öÊý¾Ý¿â²éÕÒµÄÎÊÌ⣬Á¬½Ó²éÕÒ£¬ÏÖÔÚÓÐÈý¸ö±íusers ±í£¬sex±í£¬languages±í£¬sex±íÖеÄlang_id ºÍmotherlang_idÊÇÖ÷¼üÍâ¼ü¹Øϵ
ͼƬ£º
ÁªºÏ²éÕÒÐÅϢʱ
Èç¹ûÐÅÏ¢ÍêÕûµÄ»°ÊÇ¿ÉÒÔ²éÕÒ³öÀ´µÄ£¬µ«ÊÇÐÅÏ¢²»ÍêÕûµÄ»°¾Í²îÕÒ²»³öÀ´¡££¨Èç Óû§tanaka¾ÍÎÞ·¨²é³öÐÅÏ¢£©²éÕÒÓï¾äÈçÏ£º
select users.id,username,sex_name ......

SQL¾­µä¶ÌС´úÂëÊÕ¼¯ 2

sqlserverµÄ¼¸¸öº¯ÊýÒª¼Ç¼
½ñÈÕÅöµ½¸öÎÊÌ⣺ҪʵÏÖÊý¾Ý±íÖеÄÒ»¸ö×Ö¶ÎÖеÄÎı¾Îª"xxx.gif"µÄת»»Îª"xxx.jpg",ÎÒ²»ÖªµÀÆä¾ßÌåÃû³Æ£¬Ö»ÖªµÀÊÇÒÔgif½áβ¡£
ÎÊÌâ½â¾ö£ºupdate pet set petPhoto=substring(petPhoto,1,datalength(petPhoto)-3)+'jpg' where petPhoto like '%.gif'
×¢ÒâÆ¥Åä·û£º“%& ......

SQL Server 2008³É¾ÍÆóÒµÊý¾Ýƽ̨

 
 
±¾ÎĹؼü´Ê£ºSQL 2008 SQL SQL Server SQL Server 2008
¶ÔÓÚ¼´½«ÔÚ2008Äê¡ÖØ·¢²¼µÄSQL Server 2008£¬Î¢ÈíÆÚÍûÊг¡²»½ö½öÊÇ°ÑËü×÷Ϊ¹ØϵÊý¾Ý¿âϵͳÀ´¿´´ý£¬Î¢Èí½«Æ䶨λΪһ¸öÆóÒµÊý¾Ýƽ̨£¬ËäÈ»¹ØϵÊý¾Ý¿âÒýÇæÈÔÈ»ÊÇSQL Server 2008µÄºËÐÄ£¬²»¹ýSQL Server 2008ËùÄÜÌṩµÄ·þÎñ¹ã¶È½«Ô¶³¬¹ý¼òµ¥µÄ¹ØϵÊý¾ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ