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

SQL SERVERÒìµØ±¸·Ý·½·¨(2)

 
/*Á½ÖÖ·½·¨µÄÇ°Ì᣺1.±¾µØ·þÎñÆ÷µÄsqlserver agent·þÎñ±£Ö¤´¦ÓÚÆô¶¯×´Ì¬
   2.Ô¶³Ì¼ÆËã»ú£¨¼ÆËã»ú¹ÜÀíÀ½¨Á¢Ò»¸öÆÕͨȨÏÞÓû§£¬²¢ÎªÆä¼ÓÉÏÃÜÂ루ÀýÈçÓû§ÃûΪkyle£¬ÃÜÂëΪ1234£©£¬Í¬Ê±ÔÚÄÇ̨»úÆ÷µÄ·ÇϵͳÅÌÀィһ¸öÃûΪbackupµÄ¹²ÏíÎļþ¼Ð£¬ÎªÁË°²È«ÁíÍâÉèÖÃÕâ¸öÎļþ¼ÐÖ»ÓÐÕâ¸ökyleÓû§¿ÉÒÔ·ÃÎÊ£¨ÐèÒªntfs¸ñʽ²Å¿ÉÒÔÉèÖð²È«£©*/
-----------------------------------------------------------------------------------------------------------------------
--·½·¨1£ºÓÓjob£¨×÷Òµ£©”×ö
declare @sql varchar(500)
select @sql='\\10.2.0.12\backup\dbname'+'_db_'+convert(varchar(10),getdate(),112) +
substring(convert(varchar(10),getdate(),108),1,2) +'.bak'
exec master..xp_cmdshell 'net use \\10.2.0.12\backup 1234 /user:remotehost\kyle'
backup database dbname to disk=@sql --±¸·ÝÊý¾Ý¿â£¬ÕâÀïµÄ10.2.0.12ΪԶ³Ì¼ÆËã»úµÄip£¬backupΪ¹²ÏíÎļþ¼ÐÃû£¬dbnameΪ±¾µØsqlserver·þÎñÆ÷Òª±¸·ÝµÄÊý¾Ý¿â£¬remotehostΪԶ³Ì¼ÆËã»úµÄ¼ÆËã»úÃû£¬1234ΪÃÜÂë,kyleΪÓû§Ãû£¬ÇëÏàÓ¦Ìæ»»³Éʵ¼Ê»·¾³µÄÊý¾Ý
go
declare @sql varchar(500)
select @sql='del '+'\\10.2.0.12\backup\dbname'+'_db_'+convert(varchar(10),dateadd(day,-7,getdate()),112) +
substring(convert(varchar(10),dateadd(day,-7,getdate()),108),1,2) +'.bak'
exec master..xp_cmdshell @sql --ɾ³ý7ÌìÇ°µÄ±¸·Ý£¬Ò²¾ÍÊÇÖ»±£Áô7¸ö×îб¸·Ý
go
-----------------------------------------------------------------------------------------------------------------------
--·½·¨2£ºÓÓÊý¾Ý¿âά»¤¼Æ»®”×ö
1.±¾µØ·þÎñÆ÷£¨¼ÆËã»ú¹ÜÀíÀ½¨Á¢Ò»¸ö²Ù×÷ϵͳÓû§£¬ÀýÈçkyle£¨Óû§ÃûºÍÃÜÂëÐèÒª¸úÔ¶³Ì¼ÆËã»úËù½¨Á¢µÄÓû§Çé¿öÏàͬ£©£¬¸³Óè´ËÓû§administrators×éȨÏÞ£¬¼ÓÉÏÏàÓ¦µÄÃÜÂë¡£
2.ÔÚÆóÒµ¹ÜÀíÆ÷→ÓÒ¼üµã»÷(local)(windows nt)Ñ¡ÔñÊôÐÔ→ÔÚ“°²È«ÐԔѡÏîÀïµÄ“Æô¶¯·þÎñÕÊ»§”Ñ¡ÔñʹÓÓ±¾ÕʺŔ£¬ÔÚÀïÃæÌîÈëµÚÒ»²½½¨Á¢µÄÓû§ºÍÃÜÂ루kyle£©¡££¨ÕâÀïµÄ¹¦ÄÜÊÇ£ºÓÃÕâ¸ö¸úÔ¶³Ì¼ÆËã»úÓû§ÃûÃÜÂëÒ»ÑùµÄÓû§À´Æô¶¯±¾µØsqlserver£¬¾ÍÏñ×öÁËnet use£©
3.´ýkyleÓû§ÖØÆôÁËsqlserver·þÎñºó£¬ÔÚÊý¾Ý¿âά»¤¼Æ»®ÀïµÄ“Ö¸¶¨±¸·Ý´ÅÅÌĿ¼&rdqu


Ïà¹ØÎĵµ£º

Éú³ÉÊ¡ÊеÄSQL½Å±¾

 --Ê¡¼¶   Provincial
--³ÇÊР  City
create table Provincial(pid int,Provincial varchar(50),primary key (pid))
insert into Provincial values(1,'±±¾©ÊÐ')
insert into Provincial values(2,'Ìì½òÊÐ')
insert into Provincial values(3,'ÉϺ£ÊÐ')
insert into Provincial values(4,'Ö ......

SQL 2008ÖеÄÍÚ¾òÄ£ÐÍ

SQL Server 2008 Áª»ú´ÔÊ飨2009 Äê 7 Ô£©
ÍÚ¾òÄ£ÐÍ£¨Analysis Services - Êý¾ÝÍÚ¾ò£©
±¾½Ú½éÉÜÁËÊý¾ÝÍÚ¾òÄ£Ð͵Ļù±¾Ìåϵ½á¹¹£¬¸ÅÊöÁËÊý¾ÝÍÚ¾òÄ£Ð͵ÄÊôÐÔ£¬²¢ËµÃ÷ÁË´´½¨ºÍ´¦ÀíÍÚ¾òÄ£Ð͵ķ½Ê½¡£
Mining Model Architecture
Defining Mining Models
Mining Model Properties
Mining Model Columns
Processing Min ......

ä¯ÀÀLINQ to SQL¹Øϵ

±êÇ©£ºÊý¾Ý·ÃÎÊ     LINQ     LINQ to SQL ²¿·Ö
ä¯ÀÀLINQ to SQL¹Øϵ      Á½¸ö¹ØÁªµÄ±í£º
 & ......

sql serverÊÓͼµÄ×÷Óã¨×ª£©

    ËùνÊÓͼ£¨View£©ÆäʵÊÇÖ´ÐвéѯÓï¾äºóµÃµ½µÄ½á¹û£¬µ«Õâ¸ö²éѯ½á¹û¿ÉÒÔ·ÂÕæ³ÉÊý¾Ý±íÀ´Ê¹Óã¬ËùÒÔÓÐÈËÒ²³ÆËüΪ“ÐéÄâÊý¾Ý±í”£¬ÊÓͼÔÚ²Ù×÷ÉϺÍÊý¾Ý±íûÓÐʲôÇø±ð£¬µ«Á½ÕߵIJîÒìÊÇÆä±¾ÖÊÊDz»Í¬µÄ£ºÊý¾Ý±íÊÇʵ¼Ê´æ´¢¼Ç¼µÄµØ·½£¬È»¶øÊÓͼ²¢²»±£´æÈκμǼ£¬Ëü´æ´¢µÄʵ¼ÊÉÏÊDzéѯÓï¾ä£¬ÆäËù³ÊÏÖ³ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ