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

SQL Server±¸·Ý¶Áд½ÒÃØ

ÏÂͼÏÔʾÁËÊý¾Ý¿â±¸·ÝʱÎļþ¶ÁдµÄ¹ý³Ì£º

ÔÚ±¸·ÝÆڼ䣬SQL Server»áÔÚÊý¾Ý¿âÎļþÕâ±ßΪÿһÅÌ·û(Volume)´´½¨Ò»¸ö¶ÁÏ̡߳£¶ÁÏ̵߳Ť×÷ºÜ¼òµ¥£¬¾ÍÊÇ´ÓÎļþÖеÄÊý¾ÝÄÚÈÝ¡£Ã¿´ÎÕâ¸öÏ̶߳¼»á´ÓÎļþÖжÁ³ö²¿·ÖÊý¾Ý£¬È»ºó°ÑÊý¾Ý´æµ½»º³åÖÐ(buffer)¡£ÒòΪÓжà¸ö»º³å¿ÉÓã¬ËùÒÔÖ»ÒªÓлº³å¿ÉÒÔдÈëÊý¾Ý£¬¶ÁÏ߳̿ÉÒÔ²»Í£µÄ¶ÁÊý¾Ý¡£SQL ServerҲͬʱ´´½¨Ò»¸öдỊ̈߳¬°Ñ»º³åÖеÄÊý¾ÝдÈë´ÅÅÌ»òÊÇ´Å´ø»úÉÏ¡£Ò»µ©»º³åÖеÄÊý¾Ý±»Ð´Ïß³Ìдµ½ÆäËû½éÖÊÖкó£¬ÄÇô¶ÁÏ߳̾ͿÉÒÔÔÙ´ÎÖØÓÃÕâ¸ö»º³åÇøÁË¡£
ÀýÈçÈçÏÂÃüÁ
BACKUP DATABASE AdventureWorks TO
   DISK = 'M:\backups\AdventureWorks_FULL_01.bak',
   DISK = 'N:\backups\AdventureWorks_FULL_02.bak'
WITH BUFFERCOUNT = 10, MAXTRANSFERSIZE = 1048576
¼ÙÉèAdventureWorksÎļþ±»·Ö±ð´æ´¢ÔÚÈý¸öÅÌ·ûÖУ¬±¸·Ý¹ý³Ì¾ÍÈçÏÂͼËùʾ£º

×¢Ò⣺SQL Server²»ÄÜÇø·ÖÂß¼­ÅÌ·ûºÍÎïÀíÅÌ·û¡£ÀýÈçÉÏÃæµÄÀý×Ó£¬¼ÙÈçE:\,F:\ºÍG:\ÊÇÎïÀí´ÅÅÌÉϵÄÈý¸ö·ÖÇø£¬ÄÇôÈÔÈ»ÓÐÈý¸ö¶ÁÏß³ÌÔÚ¶ÁÈ¡Êý¾ÝÎļþ¡£Èç¹ûÄãµÄ´ÅÅ̲»ÄÜÂú×ãÕâ¸ö¶ÁÈ¡ÐèÇó£¬ÄÇô±¸·ÝµÄÍÌÍÂÁ¿¾Í»áÊܵ½¼«´óµÄÓ°Ïì¡£
Èç¹ûûÓÐʹÓÃBUFFERCOUNTºÍMAXTRANSFERSIZEÕâÁ½¸ö²ÎÊýµÄ»°£¬SQL Server»á×Ô¶¯¾ö¶¨ÎªÃ¿¸öbuffer·ÖÅä¶àÉٿռ䡣±¸·ÝbufferµÄ×Ü¿Õ¼äԼΪBUFFERCOUNT*MAXTRANSFERSIZE(bytes)¼ÓÉÏһЩ¶îÍâµÄÍ·Îļþ¡£ÕâЩÄÚ´æÀ´×Ô·Ç»º´æ³ØÄÚÈÝÇøÓò£¬¾ÍÊDZ»³Æ×öMemToLeaveµÄÄÚ´æÇøÓò¡£Èç¹ûÄãÖ¸¶¨µÄ¿Õ¼ä´óÓÚ¿ÉÓÿռ䣬SQL Server»áÌáʾÈçÏ´íÎó£º
Server: Msg 701, Level 17, State 1, Line 1
There is insufficient system memory to run this query.
Server: Msg 3013, Level 16, State 1, Line 1
BACKUP DATABASE is terminating abnormally.
Èç¹ûÄãÏëÈ·¶¨SQL Server±¸·Ýʱ»º³å(buffer)µÄ´óСºÍÊý¾Ý£¬Äã¿ÉÒÔ´ò¿ª3605ºÍ3213µÄTrace±êʶ¡£SQL ServerÈÕÖ¾ÀïÃæ¼Ç¼µÄÖµÀàËÆÓÚ£º
2008-07-14 17:21:20.65 spid51 BufferPoolLimit: 100 MB
2008-07-14 17:21:20.65 spid51 Backup/Restore buffer configuration parameters
2008-07-14 17:21:20.65 spid51 Buffer count: 15
2008-07-14 17:21:20.65 spid51 Max transfer size: 983040
2008-07-14 17:21:20.65 spid51 Total buffer space: 14 MB
2008-07-14 17:21:20.65 spid51 Buffers per read stream: 15
2008-07-14 17:21:20.65 spid51 Buffers per write stream: 5
2008-0


Ïà¹ØÎĵµ£º

SQLѧϰ֮Á¬½Ó·û£¬ÊýÖµÔËË㣬º¯Êý

create table bookitem
(
bookname varchar(80) not null,
book_price Decimal(5,2) not null,
quantity int not null
)
 
insert into bookitem values('Image Processing',34.95,8)
insert into bookitem values('Signal Processing',51.75,6)
insert into bookitem values('Singal And System',48.5,10) ......

Transact SQL Óï ¾ä ¹¦ ÄÜ

Transact SQL  Óï ¾ä ¹¦ ÄÜ
========================================================================
¡¡¡¡--Êý¾Ý²Ù×÷
¡¡¡¡ SELECT --´ÓÊý¾Ý¿â±íÖмìË÷Êý¾ÝÐкÍÁÐ
¡¡¡¡¡¡¡¡¡¡¡¡INSERT --ÏòÊý¾Ý¿â±íÌí¼ÓÐÂÊý¾ÝÐÐ
¡¡¡¡¡¡¡¡¡¡¡¡DELETE --´ÓÊý¾Ý¿â±íÖÐɾ³ýÊý¾ÝÐÐ
¡¡¡¡¡¡¡¡¡¡¡¡UPDATE --¸üÐÂÊý¾Ý¿â±íÖеÄÊý¾Ý ......

ÈçºÎÌá¸ßSQL ServerµÄ°²È«ÐÔ£¿

1ÏÞÖÆ SQL Server·þÎñµÄȨÏÞ
¡¡¡¡
¡¡¡¡SQL Server 2000 ºÍ SQL Server Agent ÊÇ×÷Ϊ Windows ·þÎñÔËÐеġ£Ã¿¸ö·þÎñ±ØÐëÓëÒ»¸ö Windows ÕÊ»§Ïà¹ØÁª£¬²¢´ÓÕâ¸öÕÊ»§ÖÐÑÜÉú³ö°²È«ÐÔÉÏÏÂÎÄ¡£SQL ServerÔÊÐísa µÇ¼µÄÓû§£¨ÓÐʱҲ°üÀ¨ÆäËûÓû§£©À´·ÃÎʲÙ×÷ϵͳÌØÐÔ¡£ÕâЩ²Ù×÷ϵͳµ÷ÓÃÊÇÓÉÓµÓзþÎñÆ÷½ø³ÌµÄÕÊ»§µÄ°²È«ÐÔÉÏÏÂÎÄÀ´´ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ