??????SQL Server?校?????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????

??????1??????????????

?????????????????????????????????????????????????????????????????

???????????????????????????????

?????????backup database ??????? to ?????璞�?? with [name='?????????'][init /noinit]


<SPAN style="FONT-SIZE: 18px">backup database MagDB to MagDb_1 with init</SPAN>


?????????restore database ??????? from ?????璞�??  with [norecovery/recovery]


<SPAN style="FONT-SIZE: 18px">restore database MagDb
from MagDb_1
with norecovery</SPAN>


??????2????????????????????

??????????????????????????????????????????

????????????????????????????????????尾?????

?????????backup database ??????? to ?????璞�?? with differential  [name='?????????']


<SPAN style="FONT-SIZE: 18px">backup database MagDb to MagDb_1 defferential</SPAN>


?????????restore database ??????? from ?????璞�??  with [norecovery/recovery]


<SPAN style="FONT-SIZE: 18px">restore database MagDb
from MagDb_1
with file =2??
recovery</SPAN>


??????3?????????????????

????????????????????????械????????????????????????????????

??????????????????????????????????????????????????????????????????????????????????????????????????????????谢??????????????????????械???????????????????械????????????????????????????????????????????????尾?????????????????尾??????????械????????????????

?????????backup log ??????? to ?????璞�?? with init/noinit


<SPAN style="FONT-SIZE: 18px">backup log DocDb to disk='c:databakDocDb_1.bat'</SPAN>


?????????restore log ??????? from ?????璞�?? with [norecovery/recovery]


<SPAN style="FONT-SIZE: 18px">restore log DocDb
from disk='c:databakDocDb1.bat'</SPAN>


??????4???????????楸�??????

??????????????????????????????椋�???????????????????????

??????????????????????????械?????????????????????

?????????backup database ???????  file='????????????'??filegroup) to ?????璞�?? with init/noinit


<SPAN style="FONT-SIZE: 18px">backup database DocDb
file='DocDb_Data'
to disk='c:databakDocfile1.dat'</SPAN>


?????????restore database ???????  file='????????????'??filegroup) from ?????璞�??


<SPAN style="FONT-SIZE: 18px">restore database DocDb
file="DocDb_Data"
from disk="c:databakDocfile1.dat"</SPAN>


????????????????????????????????????????绶�???