zh-hant/Microsoft.SqlServer.Management.PSSnapins.dll-Help.xml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 |
<?xml version="1.0" encoding="utf-8"?>
<helpItems xmlns="http://msh" schema="maml"> <command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Add-SqlAvailabilityDatabase</command:name><maml:description><maml:para>將一個或多個主要資料庫或是一個或多個次要資料庫加入或聯結至 InputObject 或 Path 參數中指定的可用性群組。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Add</command:verb><command:noun>SqlAvailabilityDatabase</command:noun><dev:version /></command:details><maml:description><maml:para>Add-SqlAvailabilityDatabase Cmdlet 會將一個或多個主要資料庫或是一個或多個次要資料庫加入或聯結至 InputObject 或 Path 參數中指定的可用性群組。 </maml:para><maml:para>若要將一個或多個資料庫加入至可用性群組,請在裝載主要複本的伺服器執行個體上執行這個 Cmdlet,並且指定一個或多個本機使用者資料庫。 </maml:para><maml:para>若要將次要資料庫聯結至可用性群組,請在裝載次要複本的伺服器執行個體上手動準備次要資料庫,然後在裝載次要複本的伺服器執行個體上執行這個 Cmdlet。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Add-SqlAvailabilityDatabase</maml:name><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>指定要加入或聯結至 Path 或 InputObject 參數中指定之可用性群組的一個或多個使用者資料庫陣列。這些資料庫必須位於 SQL Server 的本機執行個體上。請注意,給定的資料庫只能屬於一個可用性群組。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Add-SqlAvailabilityDatabase</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>您要加入或聯結資料庫之目標可用性群組的 AvailabilityGroup 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>指定要加入或聯結至 Path 或 InputObject 參數中指定之可用性群組的一個或多個使用者資料庫陣列。這些資料庫必須位於 SQL Server 的本機執行個體上。請注意,給定的資料庫只能屬於一個可用性群組。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>指定要加入或聯結至 Path 或 InputObject 參數中指定之可用性群組的一個或多個使用者資料庫陣列。這些資料庫必須位於 SQL Server 的本機執行個體上。請注意,給定的資料庫只能屬於一個可用性群組。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>您要加入或聯結資料庫之目標可用性群組的 AvailabilityGroup 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue><dev:type><maml:name>Target</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.AvailabilityGroup</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Add-SqlAvailabilityDatabase -Path SQLSERVER:\SQL\PrimaryServer\InstanceName\AvailabilityGroups\MyAG -Database "MyDatabase" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將資料庫 'MyDatabase' 加入至可用性群組 'MyAG'。此命令 (必須在可用性群組的主要伺服器執行個體上執行) 不會準備次要資料庫以進行資料同步處理。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Add-SqlAvailabilityDatabase -Path SQLSERVER:\SQL\SecondaryServer\InstanceName\AvailabilityGroups\MyAG -Database "MyDatabase" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將次要資料庫 'MyDatabase' 聯結至裝載次要複本之其中一個伺服器執行個體上的可用性群組 'MyAG'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$DatabaseBackupFile = "\\share\backups\MyDatabase.bak" $LogBackupFile = "\\share\backups\MyDatabase.trn" $MyAgPrimaryPath = "SQLSERVER:\SQL\PrimaryServer\InstanceName\AvailabilityGroups\MyAg" $MyAgSecondaryPath = "SQLSERVER:\SQL\SecondaryServer\InstanceName\AvailabilityGroups\MyAg" Backup-SqlDatabase -Database "MyDatabase" -BackupFile $DatabaseBackupFile -ServerInstance "PrimaryServer\InstanceName" Backup-SqlDatabase -Database "MyDatabase" -BackupFile $LogBackupFile -ServerInstance "PrimaryServer\InstanceName" -BackupAction 'Log' Restore-SqlDatabase -Database "MyDatabase" -BackupFile $DatabaseBackupFile -ServerInstance "SecondaryServer\InstanceName" -NoRecovery Restore-SqlDatabase -Database "MyDatabase" -BackupFile $LogBackupFile -ServerInstance "SecondaryServer\InstanceName" -RestoreAction 'Log' -NoRecovery Add-SqlAvailabilityDatabase -Path $MyAgPrimaryPath -Database "MyDatabase" Add-SqlAvailabilityDatabase -Path $MyAgSecondaryPath -Database "MyDatabase" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會示範下列完整程序:根據裝載可用性群組之主要複本的伺服器執行個體上的資料庫準備次要資料庫、將資料庫加入至可用性群組 (做為主要資料庫),然後將次要資料庫聯結至可用性群組。首先,此範例會備份資料庫及其交易記錄。然後,此範例會將資料庫和記錄備份還原至裝載次要複本的伺服器執行個體。此範例會呼叫 Add-SqlAvailabilityDatabase 兩次:第一次是針對主要複本呼叫,以便將資料庫加入至可用性群組,然後再針對次要複本呼叫,以便將該複本的次要資料庫聯結至可用性群組。如果您有多個次要複本,請還原並聯結每個次要複本的次要資料庫。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 4 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Add-SqlAvailabilityDatabase -Path SQLSERVER:\SQL\PrimaryServer\InstanceName\AvailabilityGroups\MyAG -Database "MyDatabase" -Script </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會輸出 Transact-SQL 指令碼,這個指令碼會將資料庫 'MyDatabase' 加入至可用性群組 'MyAG'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>SQL Server Books Online: Adding a Database to an Availability Group (SQL Server)</maml:linkText><maml:uri /></maml:navigationLink><maml:navigationLink><maml:linkText>SQL Server Books Online: Joining a Secondary Replica to an Availability Group (SQL Server)</maml:linkText><maml:uri /></maml:navigationLink><maml:navigationLink><maml:linkText>SQL Server Books Online: Specifying the Endpoint URL for an Availability Replica (SQL Server)</maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Add-SqlAvailabilityGroupListenerStaticIp</command:name><maml:description><maml:para>將靜態 IP 位址加入至現有的可用性群組接聽程式組態。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Add</command:verb><command:noun>SqlAvailabilityGroupListenerStaticIp</command:noun><dev:version /></command:details><maml:description><maml:para>Add-SqlAvailabilityGroupListenerStaticIp Cmdlet 會將靜態 IP 位址加入至現有的可用性群組接聽程式組態。可接受 AvailabilityGroupListener、路徑和靜態 IP 位址做為參數。IP 位址可以是包含子網路的 IPv4 位址或 IPv6 位址。這個 Cmdlet 只能在裝載主要複本的伺服器執行個體上執行。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Add-SqlAvailabilityGroupListenerStaticIp</maml:name><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組接聽程式的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StaticIp</maml:name><maml:description><maml:para>要加入至可用性群組接聽程式的靜態 IP 位址。這個引數應該是字串清單。每個字串都可以是採用斜線標記法的 IPv4 位址和子網路遮罩 (例如 192.168.1.1/255.255.255.0) 或 IPv6 位址。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Add-SqlAvailabilityGroupListenerStaticIp</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>您要加入 IP 位址之目標接聽程式的 AvailabilityGroupListener 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StaticIp</maml:name><maml:description><maml:para>要加入至可用性群組接聽程式的靜態 IP 位址。這個引數應該是字串清單。每個字串都可以是採用斜線標記法的 IPv4 位址和子網路遮罩 (例如 192.168.1.1/255.255.255.0) 或 IPv6 位址。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>您要加入 IP 位址之目標接聽程式的 AvailabilityGroupListener 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue><dev:type><maml:name>Target</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組接聽程式的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StaticIp</maml:name><maml:description><maml:para>要加入至可用性群組接聽程式的靜態 IP 位址。這個引數應該是字串清單。每個字串都可以是採用斜線標記法的 IPv4 位址和子網路遮罩 (例如 192.168.1.1/255.255.255.0) 或 IPv6 位址。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.AvailabilityGroupListener</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$path = "SQLSERVER:\SQL\PrimaryServer\InstanceName\AvailabilityGroups\MyAg\AvailabilityGroupListeners\MyListener" Add-SqlAvailabilityGroupListenerStaticIp -Path $path -StaticIp "2001:0db8:85a3:0000:0000:8a2e:0370:7334" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會將靜態 IPv4 位址加入至可用性群組 'MyAg' 的可用性群組接聽程式 'MyListener'。這個 IPv4 位址會做為子網路 255.255.252.0 之接聽程式的虛擬 IP 位址。如果可用性群組跨越多個子網路,您就應該將每個子網路的靜態 IP 位址加入至接聽程式。Add-SqlAvailabilityGroupListenerStaticIp 命令必須在裝載主要複本的伺服器執行個體上執行。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$path = "SQLSERVER:\SQL\PrimaryServer\InstanceName\AvailabilityGroups\MyAg\AvailabilityGroupListeners\MyListener" Add-SqlAvailabilityGroupListenerStaticIp -Path $path -StaticIp "2001:0db8:85a3:0000:0000:8a2e:0370:7334" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將靜態 IPv6 位址加入至可用性群組 'MyAg' 的接聽程式 'MyListener'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$path = "SQLSERVER:\SQL\PrimaryServer\InstanceName\AvailabilityGroups\MyAg\AvailabilityGroupListeners\MyListener" Add-SqlAvailabilityGroupListenerStaticIp -Path $path -StaticIp "192.168.0.1/255.255.255.0" -Script </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會輸出 Transact-SQL 指令碼,這個指令碼會將靜態 IPv4 位址加入至可用性群組 'MyAg' 的接聽程式 'MyListener'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Add-SqlFirewallRule</command:name><maml:description><maml:para>加入 Windows 防火牆規則,以允許特定 SQL Server 執行個體的連線。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Add</command:verb><command:noun>SqlFirewallRule</command:noun><dev:version /></command:details><maml:description><maml:para>加入 Windows 防火牆規則,以允許指定 SQL Server 執行個體的連線。</maml:para><maml:para>SQL Server 雲端配接器必須在主控 SQL Server 執行個體的電腦上執行及存取。</maml:para><maml:para>這個 Cmdlet 支援下列作業模式:</maml:para><maml:para>1.透過指定執行個體 PowerShell 路徑。</maml:para><maml:para>2.透過指定伺服器物件。</maml:para><maml:para>3.透過指定目標 SQL Server 執行個體的 ServerInstance。</maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Add-SqlFirewallRule</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Add-SqlFirewallRule</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>目標 SQL Server 執行個體的伺服器物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">Server[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Add-SqlFirewallRule</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>此參數可指定將成為作業目標之 SQL Server 執行個體的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue><dev:type><maml:name>PSCredential</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>目標 SQL Server 執行個體的伺服器物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">Server[]</command:parameterValue><dev:type><maml:name>Server[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>此參數可指定將成為作業目標之 SQL Server 執行個體的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>CD SQLSERVER:\SQL\Computer\Instance; Add-SqlFirewallRule -Credential $credential -AcceptSelfSignedCertificate; </dev:code><dev:remarks><maml:para>此命令會將 Windows 防火牆規則加入電腦 'Computer',以允許此電腦上的 SQL Server 'Instance' 之執行個體的連線。目前的工作目錄會用來決定應該進行作業的伺服器執行個體。系統會自動接受目標電腦的自我簽署憑證,而不提示使用者。</maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>This command retrieves all instances of SQL Server on the machine ‘MachineName’ and adds Windows Firewall rules to allow connections for each one of them. The self-signed certificate of the target machine will be automatically accepted without prompting the user. PS C:\>Get-SqlInstance -Credential $credential -MachineName "MachineName" | Add-SqlFirewallRule -Credential $credential -AcceptSelfSignedCertificate; </dev:code><dev:remarks><maml:para></maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>Online Version:</maml:linkText><maml:uri></maml:uri></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Backup-SqlDatabase</command:name><maml:description><maml:para>Backup-SqlDatabase Cmdlet 會在 SQL Server 資料庫上執行備份作業。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Backup</command:verb><command:noun>SqlDatabase</command:noun><dev:version /></command:details><maml:description><maml:para>Backup-SqlDatabase Cmdlet 會在 SQL Server 資料庫上執行備份作業。這包括完整資料庫備份、交易記錄備份和資料庫檔案備份。這個 Cmdlet 是依照 Microsoft.SqlServer.Management.Smo.Backup 類別建立的。此類別的參數通常會對應至該 Smo 物件的屬性。 </maml:para><maml:para>這個 Cmdlet 支援四種作業模式,可備份伺服器執行個體上具有指定名稱的資料庫。 </maml:para><maml:para>1.將伺服器執行個體的路徑傳遞給 -Path 參數,並將資料庫名稱傳遞給 -Database 參數。 </maml:para><maml:para>2.將 Smo.Server 物件傳遞給 -InputObject 參數 (直接或透過管線),並將資料庫名稱傳遞給 -Database 參數。 </maml:para><maml:para>3.將伺服器執行個體的名稱傳遞給 -ServerInstance 參數,並將資料庫名稱傳遞給 -Database 參數。 </maml:para><maml:para>4.將 Smo.Database 物件傳遞給 -DatabaseObject 參數 (直接或透過管線)。 </maml:para><maml:para>根據預設,此 Cmdlet 會執行完整資料庫備份。您可以透過指定 -BackupAction 參數,設定備份的類型。 </maml:para><maml:para>根據預設,備份檔案會以 "databasename.bak" (完整及/或檔案備份) 和 "databasename.trn" (記錄備份) 的名稱儲存在預設伺服器備份位置中。 </maml:para><maml:para>您可以透過指定 -BackupFile 參數,設定備份檔案的位置和檔案名稱。請使用 BackupFile 參數指定備份檔案的完整檔名,這個完整檔名包含檔案的位置和檔案名稱。 </maml:para><maml:para>請使用 BackupContainer 參數設定備份檔案的位置。在本例中,備份檔案的名稱是自動產生的。BackupContainer 參數僅用來指定備份檔案的位置。如需詳細資訊,請參閱 BackupContainer 參數說明。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Backup-SqlDatabase</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>要備份的資料庫名稱。-Database 無法搭配 -DatabaseObject 參數使用。當 </maml:para><maml:para>您指定了 -Database 參數時,也必須指定 -Path、-InputObject 或 -ServerInstance 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>BackupFile</maml:name><maml:description><maml:para>備份檔案的位置和名稱。這是選擇性參數。如果未指定,備份就會以 "databasename.bak" (完整及檔案備份) 或 "databasename.trn" (記錄備份) 的名稱儲存在伺服器的預設備份位置中。這個參數無法搭配 BackupDevice 或 BackupContainer 參數使用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupAction</maml:name><maml:description><maml:para>要執行的備份作業類型。有效的選項包括:Database、Files 或 Log,如下所示: </maml:para><maml:para>Database:備份資料庫中的所有資料檔案。 </maml:para><maml:para>Files:備份指定的資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para><maml:para>Log:備份交易記錄。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupActionType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupContainer</maml:name><maml:description><maml:para>儲存備份的資料夾或位置,這可以是磁碟上的資料夾或 Windows Azure Blob 容器的 URL。在指定的執行個體中備份多個資料庫時,這個參數可能會很有用。這個參數無法搭配 BackupDevice 參數使用。BackupContainer 參數無法搭配 BackupFile 參數使用。 </maml:para><maml:para>注意:用來指定位置的路徑結尾必須是正斜線 (/)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupDevice</maml:name><maml:description><maml:para>儲存備份的裝置。這個參數無法搭配 BackupFile 參數使用。如果您要備份至磁帶,請使用此參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceItem[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupSetDescription</maml:name><maml:description><maml:para>備份組的選擇性描述。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupSetName</maml:name><maml:description><maml:para>備份組的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BlockSize</maml:name><maml:description><maml:para>備份的實體區塊大小 (以位元組為單位)。支援的大小為 512、1024、2048、4096、8192、16384、32768 和 65536 (64 KB) 位元組。磁帶裝置的預設值為 65536,其他裝置則為 512。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BufferCount</maml:name><maml:description><maml:para>要用於備份作業的 I/O 緩衝區總數。您可以指定任何正整數。使用許多緩衝區時,可能會因為 Sqlservr.exe 處理序中的虛擬位址空間不足而造成「記憶體不足」錯誤。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Checksum</maml:name><maml:description><maml:para>在備份作業期間計算總和檢查碼值。如果未設定,則不會計算總和檢查碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>CompressionOption</maml:name><maml:description><maml:para>備份作業的壓縮選項。選項包括 Default、On 和 Off。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupCompressionOptions</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ContinueAfterError</maml:name><maml:description><maml:para>作業會在發生總和檢查碼錯誤時繼續進行。如果未設定,則作業會在總和檢查碼錯誤之後失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>CopyOnly</maml:name><maml:description><maml:para>備份為只複製備份。只複製備份不會影響您定期排程之傳統備份的一般順序。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFile</maml:name><maml:description><maml:para>一個或多個要備份的資料庫檔案。只能在 BackupAction 屬性設定為 Files 時使用。當 BackupAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFileGroup</maml:name><maml:description><maml:para>備份作業的目標資料庫檔案群組。只能在 BackupAction 屬性設定為 Files 時使用。當 BackupAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionOption</maml:name><maml:description><maml:para>備份作業的加密選項。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptionOptions</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ExpirationDate</maml:name><maml:description><maml:para>備份組到期且不再將備份資料視為有效的日期和時間。只能用於儲存在磁碟或磁帶裝置上的備份資料。超過到期日的備份組可以由更新的備份覆寫。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">DateTime</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FormatMedia</maml:name><maml:description><maml:para>在備份作業的第一個步驟格式化磁帶。不適用於磁碟備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Incremental</maml:name><maml:description><maml:para>執行差異備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Initialize</maml:name><maml:description><maml:para>初始化與備份作業相關聯的裝置。覆寫媒體上的任何現有備份組,而且這個備份會成為媒體上的第一個備份組。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>LogTruncationType</maml:name><maml:description><maml:para>記錄備份的截斷行為。選項包括 TruncateOnly、NoTruncate 或 Truncate。根據預設,這個選項會設定為 Truncate。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupTruncateLogType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxTransferSize</maml:name><maml:description><maml:para>要在備份媒體與 SQL Server 執行個體之間傳送的最大位元組數目。可能的值是 65536 個位元組 (64 KB) 的倍數,最多 4194304 個位元組 (4 MB)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaDescription</maml:name><maml:description><maml:para>包含備份組之媒體的選擇性描述。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaName</maml:name><maml:description><maml:para>用來識別媒體集的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MirrorDevices</maml:name><maml:description><maml:para>指定鏡像備份所使用之 BackupDeviceList 物件的陣列。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceList[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRecovery</maml:name><maml:description><maml:para>不備份記錄檔的尾端。還原時,資料庫會處於還原狀態。如果未設定,則會備份記錄檔的尾端。只適用於 -BackupAction 參數設定為 Log 的情況。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRewind</maml:name><maml:description><maml:para>當備份完成時,在結束位置讓磁帶機保持開啟狀態。如果未設定,就會在作業完成之後倒轉磁帶。不適用於磁碟或 URL 備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>PassThru</maml:name><maml:description><maml:para>如果已設定,就會輸出執行備份的 Smo Backup 物件。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行備份作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Restart</maml:name><maml:description><maml:para>繼續處理部分完成的備份作業。如果未設定 (預設值),此 Cmdlet 就會在備份組的開頭重新啟動中斷的備份作業。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetainDays</maml:name><maml:description><maml:para>必須經過多少天之後,才能覆寫備份組。只能用於儲存在磁碟或磁帶裝置上的備份資料。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SkipTapeHeader</maml:name><maml:description><maml:para>略過讀取磁帶標頭。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>SQL Server Credential 物件會儲存驗證資訊。如果您要備份至 Windows Azure Blob 儲存體服務 (URL),就需要這個參數。儲存的驗證資訊包含 Windows Azure 儲存體帳戶名稱和相關的存取金鑰值。這個參數不能搭配 Disk 或 Tape 使用。您可以提供 SQL Server 認證名稱或透過管線傳遞物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UndoFileName</maml:name><maml:description><maml:para>恢復檔案的名稱,用來儲存復原期間回復的未認可交易。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UnloadTapeAfter</maml:name><maml:description><maml:para>在作業完成時倒轉並卸載磁帶裝置。如果未設定,則不會嘗試倒轉並卸載磁帶媒體。不適用於磁碟或 URL 備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Backup-SqlDatabase</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>DatabaseObject</maml:name><maml:description><maml:para>資料庫物件。系統將在此資料庫上執行備份作業。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Database</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>BackupFile</maml:name><maml:description><maml:para>備份檔案的位置和名稱。這是選擇性參數。如果未指定,備份就會以 "databasename.bak" (完整及檔案備份) 或 "databasename.trn" (記錄備份) 的名稱儲存在伺服器的預設備份位置中。這個參數無法搭配 BackupDevice 或 BackupContainer 參數使用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupAction</maml:name><maml:description><maml:para>要執行的備份作業類型。有效的選項包括:Database、Files 或 Log,如下所示: </maml:para><maml:para>Database:備份資料庫中的所有資料檔案。 </maml:para><maml:para>Files:備份指定的資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para><maml:para>Log:備份交易記錄。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupActionType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupContainer</maml:name><maml:description><maml:para>儲存備份的資料夾或位置,這可以是磁碟上的資料夾或 Windows Azure Blob 容器的 URL。在指定的執行個體中備份多個資料庫時,這個參數可能會很有用。這個參數無法搭配 BackupDevice 參數使用。BackupContainer 參數無法搭配 BackupFile 參數使用。 </maml:para><maml:para>注意:用來指定位置的路徑結尾必須是正斜線 (/)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupDevice</maml:name><maml:description><maml:para>儲存備份的裝置。這個參數無法搭配 BackupFile 參數使用。如果您要備份至磁帶,請使用此參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceItem[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupSetDescription</maml:name><maml:description><maml:para>備份組的選擇性描述。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupSetName</maml:name><maml:description><maml:para>備份組的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BlockSize</maml:name><maml:description><maml:para>備份的實體區塊大小 (以位元組為單位)。支援的大小為 512、1024、2048、4096、8192、16384、32768 和 65536 (64 KB) 位元組。磁帶裝置的預設值為 65536,其他裝置則為 512。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BufferCount</maml:name><maml:description><maml:para>要用於備份作業的 I/O 緩衝區總數。您可以指定任何正整數。使用許多緩衝區時,可能會因為 Sqlservr.exe 處理序中的虛擬位址空間不足而造成「記憶體不足」錯誤。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Checksum</maml:name><maml:description><maml:para>在備份作業期間計算總和檢查碼值。如果未設定,則不會計算總和檢查碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>CompressionOption</maml:name><maml:description><maml:para>備份作業的壓縮選項。選項包括 Default、On 和 Off。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupCompressionOptions</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ContinueAfterError</maml:name><maml:description><maml:para>作業會在發生總和檢查碼錯誤時繼續進行。如果未設定,則作業會在總和檢查碼錯誤之後失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>CopyOnly</maml:name><maml:description><maml:para>備份為只複製備份。只複製備份不會影響您定期排程之傳統備份的一般順序。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFile</maml:name><maml:description><maml:para>一個或多個要備份的資料庫檔案。只能在 BackupAction 屬性設定為 Files 時使用。當 BackupAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFileGroup</maml:name><maml:description><maml:para>備份作業的目標資料庫檔案群組。只能在 BackupAction 屬性設定為 Files 時使用。當 BackupAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionOption</maml:name><maml:description><maml:para>備份作業的加密選項。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptionOptions</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ExpirationDate</maml:name><maml:description><maml:para>備份組到期且不再將備份資料視為有效的日期和時間。只能用於儲存在磁碟或磁帶裝置上的備份資料。超過到期日的備份組可以由更新的備份覆寫。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">DateTime</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FormatMedia</maml:name><maml:description><maml:para>在備份作業的第一個步驟格式化磁帶。不適用於磁碟備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Incremental</maml:name><maml:description><maml:para>執行差異備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Initialize</maml:name><maml:description><maml:para>初始化與備份作業相關聯的裝置。覆寫媒體上的任何現有備份組,而且這個備份會成為媒體上的第一個備份組。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>LogTruncationType</maml:name><maml:description><maml:para>記錄備份的截斷行為。選項包括 TruncateOnly、NoTruncate 或 Truncate。根據預設,這個選項會設定為 Truncate。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupTruncateLogType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxTransferSize</maml:name><maml:description><maml:para>要在備份媒體與 SQL Server 執行個體之間傳送的最大位元組數目。可能的值是 65536 個位元組 (64 KB) 的倍數,最多 4194304 個位元組 (4 MB)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaDescription</maml:name><maml:description><maml:para>包含備份組之媒體的選擇性描述。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaName</maml:name><maml:description><maml:para>用來識別媒體集的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MirrorDevices</maml:name><maml:description><maml:para>指定鏡像備份所使用之 BackupDeviceList 物件的陣列。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceList[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRecovery</maml:name><maml:description><maml:para>不備份記錄檔的尾端。還原時,資料庫會處於還原狀態。如果未設定,則會備份記錄檔的尾端。只適用於 -BackupAction 參數設定為 Log 的情況。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRewind</maml:name><maml:description><maml:para>當備份完成時,在結束位置讓磁帶機保持開啟狀態。如果未設定,就會在作業完成之後倒轉磁帶。不適用於磁碟或 URL 備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>PassThru</maml:name><maml:description><maml:para>如果已設定,就會輸出執行備份的 Smo Backup 物件。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Restart</maml:name><maml:description><maml:para>繼續處理部分完成的備份作業。如果未設定 (預設值),此 Cmdlet 就會在備份組的開頭重新啟動中斷的備份作業。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetainDays</maml:name><maml:description><maml:para>必須經過多少天之後,才能覆寫備份組。只能用於儲存在磁碟或磁帶裝置上的備份資料。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SkipTapeHeader</maml:name><maml:description><maml:para>略過讀取磁帶標頭。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>SQL Server Credential 物件會儲存驗證資訊。如果您要備份至 Windows Azure Blob 儲存體服務 (URL),就需要這個參數。儲存的驗證資訊包含 Windows Azure 儲存體帳戶名稱和相關的存取金鑰值。這個參數不能搭配 Disk 或 Tape 使用。您可以提供 SQL Server 認證名稱或透過管線傳遞物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UndoFileName</maml:name><maml:description><maml:para>恢復檔案的名稱,用來儲存復原期間回復的未認可交易。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UnloadTapeAfter</maml:name><maml:description><maml:para>在作業完成時倒轉並卸載磁帶裝置。如果未設定,則不會嘗試倒轉並卸載磁帶媒體。不適用於磁碟或 URL 備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Backup-SqlDatabase</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>要備份的資料庫名稱。-Database 無法搭配 -DatabaseObject 參數使用。當 </maml:para><maml:para>您指定了 -Database 參數時,也必須指定 -Path、-InputObject 或 -ServerInstance 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>BackupFile</maml:name><maml:description><maml:para>備份檔案的位置和名稱。這是選擇性參數。如果未指定,備份就會以 "databasename.bak" (完整及檔案備份) 或 "databasename.trn" (記錄備份) 的名稱儲存在伺服器的預設備份位置中。這個參數無法搭配 BackupDevice 或 BackupContainer 參數使用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupAction</maml:name><maml:description><maml:para>要執行的備份作業類型。有效的選項包括:Database、Files 或 Log,如下所示: </maml:para><maml:para>Database:備份資料庫中的所有資料檔案。 </maml:para><maml:para>Files:備份指定的資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para><maml:para>Log:備份交易記錄。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupActionType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupContainer</maml:name><maml:description><maml:para>儲存備份的資料夾或位置,這可以是磁碟上的資料夾或 Windows Azure Blob 容器的 URL。在指定的執行個體中備份多個資料庫時,這個參數可能會很有用。這個參數無法搭配 BackupDevice 參數使用。BackupContainer 參數無法搭配 BackupFile 參數使用。 </maml:para><maml:para>注意:用來指定位置的路徑結尾必須是正斜線 (/)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupDevice</maml:name><maml:description><maml:para>儲存備份的裝置。這個參數無法搭配 BackupFile 參數使用。如果您要備份至磁帶,請使用此參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceItem[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupSetDescription</maml:name><maml:description><maml:para>備份組的選擇性描述。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupSetName</maml:name><maml:description><maml:para>備份組的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BlockSize</maml:name><maml:description><maml:para>備份的實體區塊大小 (以位元組為單位)。支援的大小為 512、1024、2048、4096、8192、16384、32768 和 65536 (64 KB) 位元組。磁帶裝置的預設值為 65536,其他裝置則為 512。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BufferCount</maml:name><maml:description><maml:para>要用於備份作業的 I/O 緩衝區總數。您可以指定任何正整數。使用許多緩衝區時,可能會因為 Sqlservr.exe 處理序中的虛擬位址空間不足而造成「記憶體不足」錯誤。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Checksum</maml:name><maml:description><maml:para>在備份作業期間計算總和檢查碼值。如果未設定,則不會計算總和檢查碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>CompressionOption</maml:name><maml:description><maml:para>備份作業的壓縮選項。選項包括 Default、On 和 Off。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupCompressionOptions</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionTimeout</maml:name><maml:description><maml:para>在逾時失敗之前要等候伺服器連接的秒數。逾時值必須是介於 0 到 65534 之間的整數。如果指定了 0,連接嘗試就不會逾時。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ContinueAfterError</maml:name><maml:description><maml:para>作業會在發生總和檢查碼錯誤時繼續進行。如果未設定,則作業會在總和檢查碼錯誤之後失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>CopyOnly</maml:name><maml:description><maml:para>備份為只複製備份。只複製備份不會影響您定期排程之傳統備份的一般順序。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>PSCredential 物件,用來指定有權執行此作業之 SQL Server 登入的認證。 這不是用來儲存驗證資訊 (在存取 SQL Server 的外部資源時,SQL Server 會在內部使用此資訊) 的 SQL Credential 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFile</maml:name><maml:description><maml:para>一個或多個要備份的資料庫檔案。只能在 BackupAction 屬性設定為 Files 時使用。當 BackupAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFileGroup</maml:name><maml:description><maml:para>備份作業的目標資料庫檔案群組。只能在 BackupAction 屬性設定為 Files 時使用。當 BackupAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionOption</maml:name><maml:description><maml:para>備份作業的加密選項。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptionOptions</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ExpirationDate</maml:name><maml:description><maml:para>備份組到期且不再將備份資料視為有效的日期和時間。只能用於儲存在磁碟或磁帶裝置上的備份資料。超過到期日的備份組可以由更新的備份覆寫。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">DateTime</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FormatMedia</maml:name><maml:description><maml:para>在備份作業的第一個步驟格式化磁帶。不適用於磁碟備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Incremental</maml:name><maml:description><maml:para>執行差異備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Initialize</maml:name><maml:description><maml:para>初始化與備份作業相關聯的裝置。覆寫媒體上的任何現有備份組,而且這個備份會成為媒體上的第一個備份組。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>LogTruncationType</maml:name><maml:description><maml:para>記錄備份的截斷行為。選項包括 TruncateOnly、NoTruncate 或 Truncate。根據預設,這個選項會設定為 Truncate。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupTruncateLogType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxTransferSize</maml:name><maml:description><maml:para>要在備份媒體與 SQL Server 執行個體之間傳送的最大位元組數目。可能的值是 65536 個位元組 (64 KB) 的倍數,最多 4194304 個位元組 (4 MB)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaDescription</maml:name><maml:description><maml:para>包含備份組之媒體的選擇性描述。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaName</maml:name><maml:description><maml:para>用來識別媒體集的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MirrorDevices</maml:name><maml:description><maml:para>指定鏡像備份所使用之 BackupDeviceList 物件的陣列。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceList[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRecovery</maml:name><maml:description><maml:para>不備份記錄檔的尾端。還原時,資料庫會處於還原狀態。如果未設定,則會備份記錄檔的尾端。只適用於 -BackupAction 參數設定為 Log 的情況。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRewind</maml:name><maml:description><maml:para>當備份完成時,在結束位置讓磁帶機保持開啟狀態。如果未設定,就會在作業完成之後倒轉磁帶。不適用於磁碟或 URL 備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>PassThru</maml:name><maml:description><maml:para>如果已設定,就會輸出執行備份的 Smo Backup 物件。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Restart</maml:name><maml:description><maml:para>繼續處理部分完成的備份作業。如果未設定 (預設值),此 Cmdlet 就會在備份組的開頭重新啟動中斷的備份作業。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetainDays</maml:name><maml:description><maml:para>必須經過多少天之後,才能覆寫備份組。只能用於儲存在磁碟或磁帶裝置上的備份資料。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SkipTapeHeader</maml:name><maml:description><maml:para>略過讀取磁帶標頭。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>SQL Server Credential 物件會儲存驗證資訊。如果您要備份至 Windows Azure Blob 儲存體服務 (URL),就需要這個參數。儲存的驗證資訊包含 Windows Azure 儲存體帳戶名稱和相關的存取金鑰值。這個參數不能搭配 Disk 或 Tape 使用。您可以提供 SQL Server 認證名稱或透過管線傳遞物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UndoFileName</maml:name><maml:description><maml:para>恢復檔案的名稱,用來儲存復原期間回復的未認可交易。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UnloadTapeAfter</maml:name><maml:description><maml:para>在作業完成時倒轉並卸載磁帶裝置。如果未設定,則不會嘗試倒轉並卸載磁帶媒體。不適用於磁碟或 URL 備份。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>SQL Server 執行個體的名稱。這個伺服器執行個體會成為備份作業的目標。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Backup-SqlDatabase</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>要備份的資料庫名稱。-Database 無法搭配 -DatabaseObject 參數使用。當 </maml:para><maml:para>您指定了 -Database 參數時,也必須指定 -Path、-InputObject 或 -ServerInstance 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>BackupFile</maml:name><maml:description><maml:para>備份檔案的位置和名稱。這是選擇性參數。如果未指定,備份就會以 "databasename.bak" (完整及檔案備份) 或 "databasename.trn" (記錄備份) 的名稱儲存在伺服器的預設備份位置中。這個參數無法搭配 BackupDevice 或 BackupContainer 參數使用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupAction</maml:name><maml:description><maml:para>要執行的備份作業類型。有效的選項包括:Database、Files 或 Log,如下所示: </maml:para><maml:para>Database:備份資料庫中的所有資料檔案。 </maml:para><maml:para>Files:備份指定的資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para><maml:para>Log:備份交易記錄。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupActionType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupContainer</maml:name><maml:description><maml:para>儲存備份的資料夾或位置,這可以是磁碟上的資料夾或 Windows Azure Blob 容器的 URL。在指定的執行個體中備份多個資料庫時,這個參數可能會很有用。這個參數無法搭配 BackupDevice 參數使用。BackupContainer 參數無法搭配 BackupFile 參數使用。 </maml:para><maml:para>注意:用來指定位置的路徑結尾必須是正斜線 (/)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupDevice</maml:name><maml:description><maml:para>儲存備份的裝置。這個參數無法搭配 BackupFile 參數使用。如果您要備份至磁帶,請使用此參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceItem[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupSetDescription</maml:name><maml:description><maml:para>備份組的選擇性描述。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupSetName</maml:name><maml:description><maml:para>備份組的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BlockSize</maml:name><maml:description><maml:para>備份的實體區塊大小 (以位元組為單位)。支援的大小為 512、1024、2048、4096、8192、16384、32768 和 65536 (64 KB) 位元組。磁帶裝置的預設值為 65536,其他裝置則為 512。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BufferCount</maml:name><maml:description><maml:para>要用於備份作業的 I/O 緩衝區總數。您可以指定任何正整數。使用許多緩衝區時,可能會因為 Sqlservr.exe 處理序中的虛擬位址空間不足而造成「記憶體不足」錯誤。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Checksum</maml:name><maml:description><maml:para>在備份作業期間計算總和檢查碼值。如果未設定,則不會計算總和檢查碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>CompressionOption</maml:name><maml:description><maml:para>備份作業的壓縮選項。選項包括 Default、On 和 Off。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupCompressionOptions</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ContinueAfterError</maml:name><maml:description><maml:para>作業會在發生總和檢查碼錯誤時繼續進行。如果未設定,則作業會在總和檢查碼錯誤之後失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>CopyOnly</maml:name><maml:description><maml:para>備份為只複製備份。只複製備份不會影響您定期排程之傳統備份的一般順序。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFile</maml:name><maml:description><maml:para>一個或多個要備份的資料庫檔案。只能在 BackupAction 屬性設定為 Files 時使用。當 BackupAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFileGroup</maml:name><maml:description><maml:para>備份作業的目標資料庫檔案群組。只能在 BackupAction 屬性設定為 Files 時使用。當 BackupAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionOption</maml:name><maml:description><maml:para>備份作業的加密選項。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptionOptions</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ExpirationDate</maml:name><maml:description><maml:para>備份組到期且不再將備份資料視為有效的日期和時間。只能用於儲存在磁碟或磁帶裝置上的備份資料。超過到期日的備份組可以由更新的備份覆寫。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">DateTime</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FormatMedia</maml:name><maml:description><maml:para>在備份作業的第一個步驟格式化磁帶。不適用於磁碟備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Incremental</maml:name><maml:description><maml:para>執行差異備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Initialize</maml:name><maml:description><maml:para>初始化與備份作業相關聯的裝置。覆寫媒體上的任何現有備份組,而且這個備份會成為媒體上的第一個備份組。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>LogTruncationType</maml:name><maml:description><maml:para>記錄備份的截斷行為。選項包括 TruncateOnly、NoTruncate 或 Truncate。根據預設,這個選項會設定為 Truncate。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupTruncateLogType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxTransferSize</maml:name><maml:description><maml:para>要在備份媒體與 SQL Server 執行個體之間傳送的最大位元組數目。可能的值是 65536 個位元組 (64 KB) 的倍數,最多 4194304 個位元組 (4 MB)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaDescription</maml:name><maml:description><maml:para>包含備份組之媒體的選擇性描述。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaName</maml:name><maml:description><maml:para>用來識別媒體集的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MirrorDevices</maml:name><maml:description><maml:para>指定鏡像備份所使用之 BackupDeviceList 物件的陣列。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceList[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRecovery</maml:name><maml:description><maml:para>不備份記錄檔的尾端。還原時,資料庫會處於還原狀態。如果未設定,則會備份記錄檔的尾端。只適用於 -BackupAction 參數設定為 Log 的情況。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRewind</maml:name><maml:description><maml:para>當備份完成時,在結束位置讓磁帶機保持開啟狀態。如果未設定,就會在作業完成之後倒轉磁帶。不適用於磁碟或 URL 備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>PassThru</maml:name><maml:description><maml:para>如果已設定,就會輸出執行備份的 Smo Backup 物件。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Restart</maml:name><maml:description><maml:para>繼續處理部分完成的備份作業。如果未設定 (預設值),此 Cmdlet 就會在備份組的開頭重新啟動中斷的備份作業。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetainDays</maml:name><maml:description><maml:para>必須經過多少天之後,才能覆寫備份組。只能用於儲存在磁碟或磁帶裝置上的備份資料。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SkipTapeHeader</maml:name><maml:description><maml:para>略過讀取磁帶標頭。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>SQL Server Credential 物件會儲存驗證資訊。如果您要備份至 Windows Azure Blob 儲存體服務 (URL),就需要這個參數。儲存的驗證資訊包含 Windows Azure 儲存體帳戶名稱和相關的存取金鑰值。這個參數不能搭配 Disk 或 Tape 使用。您可以提供 SQL Server 認證名稱或透過管線傳遞物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UndoFileName</maml:name><maml:description><maml:para>恢復檔案的名稱,用來儲存復原期間回復的未認可交易。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UnloadTapeAfter</maml:name><maml:description><maml:para>在作業完成時倒轉並卸載磁帶裝置。如果未設定,則不會嘗試倒轉並卸載磁帶媒體。不適用於磁碟或 URL 備份。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該進行備份之位置的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">Server[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Backup-SqlDatabase</maml:name><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>BackupFile</maml:name><maml:description><maml:para>備份檔案的位置和名稱。這是選擇性參數。如果未指定,備份就會以 "databasename.bak" (完整及檔案備份) 或 "databasename.trn" (記錄備份) 的名稱儲存在伺服器的預設備份位置中。這個參數無法搭配 BackupDevice 或 BackupContainer 參數使用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupAction</maml:name><maml:description><maml:para>要執行的備份作業類型。有效的選項包括:Database、Files 或 Log,如下所示: </maml:para><maml:para>Database:備份資料庫中的所有資料檔案。 </maml:para><maml:para>Files:備份指定的資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para><maml:para>Log:備份交易記錄。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupActionType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupContainer</maml:name><maml:description><maml:para>儲存備份的資料夾或位置,這可以是磁碟上的資料夾或 Windows Azure Blob 容器的 URL。在指定的執行個體中備份多個資料庫時,這個參數可能會很有用。這個參數無法搭配 BackupDevice 參數使用。BackupContainer 參數無法搭配 BackupFile 參數使用。 </maml:para><maml:para>注意:用來指定位置的路徑結尾必須是正斜線 (/)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupDevice</maml:name><maml:description><maml:para>儲存備份的裝置。這個參數無法搭配 BackupFile 參數使用。如果您要備份至磁帶,請使用此參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceItem[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupSetDescription</maml:name><maml:description><maml:para>備份組的選擇性描述。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupSetName</maml:name><maml:description><maml:para>備份組的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BlockSize</maml:name><maml:description><maml:para>備份的實體區塊大小 (以位元組為單位)。支援的大小為 512、1024、2048、4096、8192、16384、32768 和 65536 (64 KB) 位元組。磁帶裝置的預設值為 65536,其他裝置則為 512。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BufferCount</maml:name><maml:description><maml:para>要用於備份作業的 I/O 緩衝區總數。您可以指定任何正整數。使用許多緩衝區時,可能會因為 Sqlservr.exe 處理序中的虛擬位址空間不足而造成「記憶體不足」錯誤。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Checksum</maml:name><maml:description><maml:para>在備份作業期間計算總和檢查碼值。如果未設定,則不會計算總和檢查碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>CompressionOption</maml:name><maml:description><maml:para>備份作業的壓縮選項。選項包括 Default、On 和 Off。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupCompressionOptions</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ContinueAfterError</maml:name><maml:description><maml:para>作業會在發生總和檢查碼錯誤時繼續進行。如果未設定,則作業會在總和檢查碼錯誤之後失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>CopyOnly</maml:name><maml:description><maml:para>備份為只複製備份。只複製備份不會影響您定期排程之傳統備份的一般順序。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFile</maml:name><maml:description><maml:para>一個或多個要備份的資料庫檔案。只能在 BackupAction 屬性設定為 Files 時使用。當 BackupAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFileGroup</maml:name><maml:description><maml:para>備份作業的目標資料庫檔案群組。只能在 BackupAction 屬性設定為 Files 時使用。當 BackupAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionOption</maml:name><maml:description><maml:para>備份作業的加密選項。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptionOptions</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ExpirationDate</maml:name><maml:description><maml:para>備份組到期且不再將備份資料視為有效的日期和時間。只能用於儲存在磁碟或磁帶裝置上的備份資料。超過到期日的備份組可以由更新的備份覆寫。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">DateTime</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FormatMedia</maml:name><maml:description><maml:para>在備份作業的第一個步驟格式化磁帶。不適用於磁碟備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Incremental</maml:name><maml:description><maml:para>執行差異備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Initialize</maml:name><maml:description><maml:para>初始化與備份作業相關聯的裝置。覆寫媒體上的任何現有備份組,而且這個備份會成為媒體上的第一個備份組。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>LogTruncationType</maml:name><maml:description><maml:para>記錄備份的截斷行為。選項包括 TruncateOnly、NoTruncate 或 Truncate。根據預設,這個選項會設定為 Truncate。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupTruncateLogType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxTransferSize</maml:name><maml:description><maml:para>要在備份媒體與 SQL Server 執行個體之間傳送的最大位元組數目。可能的值是 65536 個位元組 (64 KB) 的倍數,最多 4194304 個位元組 (4 MB)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaDescription</maml:name><maml:description><maml:para>包含備份組之媒體的選擇性描述。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaName</maml:name><maml:description><maml:para>用來識別媒體集的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MirrorDevices</maml:name><maml:description><maml:para>指定鏡像備份所使用之 BackupDeviceList 物件的陣列。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceList[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRecovery</maml:name><maml:description><maml:para>不備份記錄檔的尾端。還原時,資料庫會處於還原狀態。如果未設定,則會備份記錄檔的尾端。只適用於 -BackupAction 參數設定為 Log 的情況。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRewind</maml:name><maml:description><maml:para>當備份完成時,在結束位置讓磁帶機保持開啟狀態。如果未設定,就會在作業完成之後倒轉磁帶。不適用於磁碟或 URL 備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>PassThru</maml:name><maml:description><maml:para>如果已設定,就會輸出執行備份的 Smo Backup 物件。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Restart</maml:name><maml:description><maml:para>繼續處理部分完成的備份作業。如果未設定 (預設值),此 Cmdlet 就會在備份組的開頭重新啟動中斷的備份作業。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetainDays</maml:name><maml:description><maml:para>必須經過多少天之後,才能覆寫備份組。只能用於儲存在磁碟或磁帶裝置上的備份資料。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SkipTapeHeader</maml:name><maml:description><maml:para>略過讀取磁帶標頭。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>SQL Server Credential 物件會儲存驗證資訊。如果您要備份至 Windows Azure Blob 儲存體服務 (URL),就需要這個參數。儲存的驗證資訊包含 Windows Azure 儲存體帳戶名稱和相關的存取金鑰值。這個參數不能搭配 Disk 或 Tape 使用。您可以提供 SQL Server 認證名稱或透過管線傳遞物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UndoFileName</maml:name><maml:description><maml:para>恢復檔案的名稱,用來儲存復原期間回復的未認可交易。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UnloadTapeAfter</maml:name><maml:description><maml:para>在作業完成時倒轉並卸載磁帶裝置。如果未設定,則不會嘗試倒轉並卸載磁帶媒體。不適用於磁碟或 URL 備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupAction</maml:name><maml:description><maml:para>要執行的備份作業類型。有效的選項包括:Database、Files 或 Log,如下所示: </maml:para><maml:para>Database:備份資料庫中的所有資料檔案。 </maml:para><maml:para>Files:備份指定的資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para><maml:para>Log:備份交易記錄。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupActionType</command:parameterValue><dev:type><maml:name>BackupActionType</maml:name><maml:uri /></dev:type><dev:defaultValue>Microsoft.SqlServer.Management.Smo.BackupActionType.Database</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupContainer</maml:name><maml:description><maml:para>儲存備份的資料夾或位置,這可以是磁碟上的資料夾或 Windows Azure Blob 容器的 URL。在指定的執行個體中備份多個資料庫時,這個參數可能會很有用。這個參數無法搭配 BackupDevice 參數使用。BackupContainer 參數無法搭配 BackupFile 參數使用。 </maml:para><maml:para>注意:用來指定位置的路徑結尾必須是正斜線 (/)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupDevice</maml:name><maml:description><maml:para>儲存備份的裝置。這個參數無法搭配 BackupFile 參數使用。如果您要備份至磁帶,請使用此參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceItem[]</command:parameterValue><dev:type><maml:name>BackupDeviceItem[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>BackupFile</maml:name><maml:description><maml:para>備份檔案的位置和名稱。這是選擇性參數。如果未指定,備份就會以 "databasename.bak" (完整及檔案備份) 或 "databasename.trn" (記錄備份) 的名稱儲存在伺服器的預設備份位置中。這個參數無法搭配 BackupDevice 或 BackupContainer 參數使用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupSetDescription</maml:name><maml:description><maml:para>備份組的選擇性描述。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupSetName</maml:name><maml:description><maml:para>備份組的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BlockSize</maml:name><maml:description><maml:para>備份的實體區塊大小 (以位元組為單位)。支援的大小為 512、1024、2048、4096、8192、16384、32768 和 65536 (64 KB) 位元組。磁帶裝置的預設值為 65536,其他裝置則為 512。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BufferCount</maml:name><maml:description><maml:para>要用於備份作業的 I/O 緩衝區總數。您可以指定任何正整數。使用許多緩衝區時,可能會因為 Sqlservr.exe 處理序中的虛擬位址空間不足而造成「記憶體不足」錯誤。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Checksum</maml:name><maml:description><maml:para>在備份作業期間計算總和檢查碼值。如果未設定,則不會計算總和檢查碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>CompressionOption</maml:name><maml:description><maml:para>備份作業的壓縮選項。選項包括 Default、On 和 Off。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupCompressionOptions</command:parameterValue><dev:type><maml:name>BackupCompressionOptions</maml:name><maml:uri /></dev:type><dev:defaultValue>Microsoft.SqlServer.Management.Smo.BackupCompressionOptions.Default</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionTimeout</maml:name><maml:description><maml:para>在逾時失敗之前要等候伺服器連接的秒數。逾時值必須是介於 0 到 65534 之間的整數。如果指定了 0,連接嘗試就不會逾時。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ContinueAfterError</maml:name><maml:description><maml:para>作業會在發生總和檢查碼錯誤時繼續進行。如果未設定,則作業會在總和檢查碼錯誤之後失敗。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>CopyOnly</maml:name><maml:description><maml:para>備份為只複製備份。只複製備份不會影響您定期排程之傳統備份的一般順序。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>PSCredential 物件,用來指定有權執行此作業之 SQL Server 登入的認證。 這不是用來儲存驗證資訊 (在存取 SQL Server 的外部資源時,SQL Server 會在內部使用此資訊) 的 SQL Credential 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue><dev:type><maml:name>PSCredential</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>要備份的資料庫名稱。-Database 無法搭配 -DatabaseObject 參數使用。當 </maml:para><maml:para>您指定了 -Database 參數時,也必須指定 -Path、-InputObject 或 -ServerInstance 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFile</maml:name><maml:description><maml:para>一個或多個要備份的資料庫檔案。只能在 BackupAction 屬性設定為 Files 時使用。當 BackupAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFileGroup</maml:name><maml:description><maml:para>備份作業的目標資料庫檔案群組。只能在 BackupAction 屬性設定為 Files 時使用。當 BackupAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>DatabaseObject</maml:name><maml:description><maml:para>資料庫物件。系統將在此資料庫上執行備份作業。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Database</command:parameterValue><dev:type><maml:name>Database</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionOption</maml:name><maml:description><maml:para>備份作業的加密選項。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptionOptions</command:parameterValue><dev:type><maml:name>BackupEncryptionOptions</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ExpirationDate</maml:name><maml:description><maml:para>備份組到期且不再將備份資料視為有效的日期和時間。只能用於儲存在磁碟或磁帶裝置上的備份資料。超過到期日的備份組可以由更新的備份覆寫。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">DateTime</command:parameterValue><dev:type><maml:name>DateTime</maml:name><maml:uri /></dev:type><dev:defaultValue>System.DateTime.MinValue</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FormatMedia</maml:name><maml:description><maml:para>在備份作業的第一個步驟格式化磁帶。不適用於磁碟備份。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Incremental</maml:name><maml:description><maml:para>執行差異備份。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Initialize</maml:name><maml:description><maml:para>初始化與備份作業相關聯的裝置。覆寫媒體上的任何現有備份組,而且這個備份會成為媒體上的第一個備份組。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該進行備份之位置的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">Server[]</command:parameterValue><dev:type><maml:name>Server[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>LogTruncationType</maml:name><maml:description><maml:para>記錄備份的截斷行為。選項包括 TruncateOnly、NoTruncate 或 Truncate。根據預設,這個選項會設定為 Truncate。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupTruncateLogType</command:parameterValue><dev:type><maml:name>BackupTruncateLogType</maml:name><maml:uri /></dev:type><dev:defaultValue>Microsoft.SqlServer.Management.Smo.BackupTruncateLogType.Truncate</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxTransferSize</maml:name><maml:description><maml:para>要在備份媒體與 SQL Server 執行個體之間傳送的最大位元組數目。可能的值是 65536 個位元組 (64 KB) 的倍數,最多 4194304 個位元組 (4 MB)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaDescription</maml:name><maml:description><maml:para>包含備份組之媒體的選擇性描述。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaName</maml:name><maml:description><maml:para>用來識別媒體集的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MirrorDevices</maml:name><maml:description><maml:para>指定鏡像備份所使用之 BackupDeviceList 物件的陣列。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceList[]</command:parameterValue><dev:type><maml:name>BackupDeviceList[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRecovery</maml:name><maml:description><maml:para>不備份記錄檔的尾端。還原時,資料庫會處於還原狀態。如果未設定,則會備份記錄檔的尾端。只適用於 -BackupAction 參數設定為 Log 的情況。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRewind</maml:name><maml:description><maml:para>當備份完成時,在結束位置讓磁帶機保持開啟狀態。如果未設定,就會在作業完成之後倒轉磁帶。不適用於磁碟或 URL 備份。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>PassThru</maml:name><maml:description><maml:para>如果已設定,就會輸出執行備份的 Smo Backup 物件。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行備份作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Restart</maml:name><maml:description><maml:para>繼續處理部分完成的備份作業。如果未設定 (預設值),此 Cmdlet 就會在備份組的開頭重新啟動中斷的備份作業。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetainDays</maml:name><maml:description><maml:para>必須經過多少天之後,才能覆寫備份組。只能用於儲存在磁碟或磁帶裝置上的備份資料。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue>-1</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>SQL Server 執行個體的名稱。這個伺服器執行個體會成為備份作業的目標。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SkipTapeHeader</maml:name><maml:description><maml:para>略過讀取磁帶標頭。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>SQL Server Credential 物件會儲存驗證資訊。如果您要備份至 Windows Azure Blob 儲存體服務 (URL),就需要這個參數。儲存的驗證資訊包含 Windows Azure 儲存體帳戶名稱和相關的存取金鑰值。這個參數不能搭配 Disk 或 Tape 使用。您可以提供 SQL Server 認證名稱或透過管線傳遞物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue><dev:type><maml:name>PSObject</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UndoFileName</maml:name><maml:description><maml:para>恢復檔案的名稱,用來儲存復原期間回復的未認可交易。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UnloadTapeAfter</maml:name><maml:description><maml:para>在作業完成時倒轉並卸載磁帶裝置。如果未設定,則不會嘗試倒轉並卸載磁帶媒體。不適用於磁碟或 URL 備份。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>SMO.Server</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 參考應該進行備份作業之 SQL Server 執行個體的 SMO.Server 物件。 </maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Backup-SqlDatabase -ServerInstance Computer\Instance -Database MyDB </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在伺服器執行個體 'Computer\Instance' 的預設備份位置建立資料庫 'MyDB' 的完整資料庫備份。備份檔案將命名為 'MyDB.bak'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>cd SQLSERVER:\SQL\Computer\Instance Backup-SqlDatabase -Database MyDB </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在伺服器執行個體 'Computer\Instance' 的預設備份位置建立資料庫 'MyDB' 的完整資料庫備份。目前的工作目錄會用來決定應該進行備份的伺服器執行個體。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Backup-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -BackupAction Log </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在伺服器執行個體 'Computer\Instance' 的預設備份位置建立資料庫 'MyDB' 之交易記錄的備份。備份檔案會命名為 'MyDB.trn'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 4 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Backup-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -Credential (Get-Credential sa) </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會使用 sa SQL Server 登入來建立資料庫 'MyDB' 的完整資料庫備份。此命令將提示您輸入密碼以完成 SQL Server 驗證。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 5 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Backup-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -BackupFile \\share\folder\MyDB.bak </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將資料庫 'MyDB' 的完整資料庫備份建立至檔案 '\\share\folder\MyDB.bak'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 6 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Get-ChildItem SQLSERVER:\SQL\Computer\Instance\Databases | Backup-SqlDatabase </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將伺服器執行個體 'Computer\Instance' 上的所有資料庫都備份至預設備份位置。備份檔案會命名為 '<database name>.bak'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 7 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>cd SQLSERVER:\SQL\Computer\Instance\Databases foreach($database in (Get-ChildItem)) { $dbName = $database.Name Backup-SqlDatabase -Database $dbName -BackupFile "\\share\folder\$dbName.bak" } </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此指令碼會在共用 '\\share\folder' 中建立伺服器執行個體 'Computer\Instance' 上每個資料庫的完整備份。備份檔案會命名為 '<database name>.bak'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 8 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Backup-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -BackupAction Files -DatabaseFileGroup "FileGroup1","FileGroup2" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會建立次要檔案群組 'FileGroup1' 和 'FileGroup2' 中每個檔案的完整檔案備份。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 9 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Backup-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -Incremental </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在伺服器執行個體 'Computer\Instance' 的預設備份位置建立資料庫 'MyDB' 的差異備份。備份檔案會命名為 'MyDB.bak'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 10 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$tapeDevice = New-Object Microsoft.Sqlserver.Management.Smo.BackupDeviceItem("\\.\tape0", "Tape") Backup-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -BackupDevice $tapeDevice </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在磁帶裝置 '\\.\tape0' 上建立資料庫 'MyDB' 的完整備份。為了表示這個裝置,此命令會建構 Microsoft.Sqlserver.Management.Smo.BackupDeviceItem 的執行個體。該建構函式可接受兩個引數:備份裝置的名稱 ('\\.\tape0') 以及備份裝置的類型 ('Tape')。這個 BackupDeviceItem 物件會傳遞給 Backup-SqlDatabase Cmdlet 的 -BackupDevice 參數。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 11 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>Backup-SqlDatabase –ServerInstance Computer\Instance –Database –MyDB -BackupContainer "https://storageaccountname.blob.core.windows.net/containername" -SqlCredential "SQLCredentialName" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在 Windows Azure Blob 儲存體服務上建立資料庫 'MyDB' 的完整備份。此命令會使用 BackupContainer 指定 Windows Azure Blob 容器的位置 (URL),而且備份檔案的名稱是自動產生的。SqlCredential 參數是用來指定用於儲存驗證資訊之 SQL Server 認證的名稱。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 12 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>Backup-SqlDatabase –ServerInstance Computer\Instance –Database –MyDB -BackupFile "https://storageaccountname.blob.core.windows.net/containername/MyDB.bak" -SqlCredential "SQLCredentialName" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在 Windows Azure Blob 儲存體服務上建立資料庫 'MyDB' 的完整備份。此命令會使用 BackupFile 參數指定備份檔案的位置 (URL) 和名稱。SqlCredential 參數是用來指定 SQL Server 認證的名稱。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 13 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Get-ChildItem SQLSERVER:\SQL\Computer\Instance\Databases | Backup-SqlDatabase –BackupContainer "https://storageaccountname.blob.core.windows.net/containername" -SqlCredential "SQLCredentialName" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會使用 BackupContainer 參數,將伺服器執行個體 'Computer\Instance' 上的所有資料庫都備份至 Windows Azure Blob 儲存體服務位置。備份檔案的名稱是自動產生的。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 14 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$encryptionOption = New-SqlBackupEncryptionOption -Algorithm Aes256 -EncryptorType ServerCertificate -EncryptorName "BackupCert" </dev:code><dev:code>C:\PS>Backup-SqlDatabase -ServerInstance . -Database "db1" -BackupFile "db1.bak" -CompressionOption On -EncryptionOption $encryptionOption </dev:code><dev:remarks><maml:para>此範例會建立加密選項,然後將它當做 Backup-SqlDatabase 的參數值使用,以建立加密備份。</maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Disable-SqlAlwaysOn</command:name><maml:description><maml:para>在 Path、InputObject 或 ServerInstance 參數所指定的 SQL Server 執行個體上停用 AlwaysOn 可用性群組功能。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Disable</command:verb><command:noun>SqlAlwaysOn</command:noun><dev:version /></command:details><maml:description><maml:para>Disable-SqlAlwaysOn Cmdlet 會在 SQL Server 執行個體上停用 AlwaysOn 可用性群組功能。如果您在 SQL Server 服務執行時停用 AlwaysOn 可用性群組,就必須重新啟動 Database Engine 服務,才能完成變更。除非您指定 -Force 參數,否則此 Cmdlet 會詢問您是否想要重新啟動服務。如果取消,就不會進行任何作業。 </maml:para><maml:para>如果 AlwaysOn 可用性群組已經停用,這個 Cmdlet 就不會執行任何動作。 </maml:para><maml:para>這個 Cmdlet 可以針對遠端服務執行。您必須擁有系統管理員權限,才能執行這個 Cmdlet。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Disable-SqlAlwaysOn</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>有權在指定之 SQL Server 執行個體上改變 AlwaysOn 設定的 Windows 認證。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Force</maml:name><maml:description><maml:para>指定 -Force,即可強制 Cmdlet 在未經使用者確認的情況下繼續進行。提供此參數的目的是要讓您建構指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>系統不會提示使用者重新啟動 SQL Server 服務。您必須手動重新啟動 SQL Server 服務,才能讓變更生效。設定此參數時,系統會忽略 -Force。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Disable-SqlAlwaysOn</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該停用 AlwaysOn 可用性群組設定之 SQL Server 執行個體的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Server</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>有權在指定之 SQL Server 執行個體上改變 AlwaysOn 設定的 Windows 認證。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Force</maml:name><maml:description><maml:para>指定 -Force,即可強制 Cmdlet 在未經使用者確認的情況下繼續進行。提供此參數的目的是要讓您建構指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>系統不會提示使用者重新啟動 SQL Server 服務。您必須手動重新啟動 SQL Server 服務,才能讓變更生效。設定此參數時,系統會忽略 -Force。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Disable-SqlAlwaysOn</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>有權在指定之 SQL Server 執行個體上改變 AlwaysOn 設定的 Windows 認證。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Force</maml:name><maml:description><maml:para>指定 -Force,即可強制 Cmdlet 在未經使用者確認的情況下繼續進行。提供此參數的目的是要讓您建構指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>系統不會提示使用者重新啟動 SQL Server 服務。您必須手動重新啟動 SQL Server 服務,才能讓變更生效。設定此參數時,系統會忽略 -Force。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>要停用 AlwaysOn 之 SQL Server 執行個體的名稱。此格式應該是 MACHINENAME\INSTANCE。可搭配 -Credential 參數使用,以變更遠端伺服器的 AlwaysOn 設定。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>有權在指定之 SQL Server 執行個體上改變 AlwaysOn 設定的 Windows 認證。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue><dev:type><maml:name>PSCredential</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Force</maml:name><maml:description><maml:para>指定 -Force,即可強制 Cmdlet 在未經使用者確認的情況下繼續進行。提供此參數的目的是要讓您建構指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該停用 AlwaysOn 可用性群組設定之 SQL Server 執行個體的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Server</command:parameterValue><dev:type><maml:name>Server</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>系統不會提示使用者重新啟動 SQL Server 服務。您必須手動重新啟動 SQL Server 服務,才能讓變更生效。設定此參數時,系統會忽略 -Force。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>False</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>要停用 AlwaysOn 之 SQL Server 執行個體的名稱。此格式應該是 MACHINENAME\INSTANCE。可搭配 -Credential 參數使用,以變更遠端伺服器的 AlwaysOn 設定。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>SMO.Server</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 參考應該停用 AlwaysOn 之 SQL Server 執行個體的 SMO.Server 物件。 </maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name>False</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Disable-SqlAlwaysOn -Path SQLSERVER:\Sql\Computer\Instance </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在位於指定路徑的 SQL Server 執行個體上停用 AlwaysOn 可用性群組。此命令需要重新啟動伺服器執行個體,而且系統將提示您確認重新啟動。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Disable-SqlAlwaysOn -Path SQLSERVER:\Sql\Computer\Instance -Force </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在位於指定路徑的 SQL Server 執行個體上停用 AlwaysOn 可用性群組。-Force 選項會導致伺服器執行個體在不提示您確認的情況下重新啟動。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Disable-SqlAlwaysOn -ServerInstance Computer\Instance </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在名為 'Computer\Instance' 的 SQL Server 執行個體上停用 AlwaysOn 可用性群組。此命令需要重新啟動執行個體,而且系統將提示您確認重新啟動。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 4 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Disable-SqlAlwaysOn -ServerInstance Computer\Instance -Credential (Get-Credential DOMAIN\Username) </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會使用 Windows 驗證,在名為 'Computer\Instance' 的 SQL Server 執行個體上停用 AlwaysOn 可用性群組。系統將提示您輸入指定帳戶 'DOMAIN\Username' 的密碼。這項變更需要重新啟動執行個體,而且系統也將提示您確認重新啟動。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 5 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Disable-SqlAlwaysOn -Path SQLSERVER:\Sql\Computer\Instance -NoServiceRestart </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在位於指定路徑的 SQL Server 執行個體上停用 AlwaysOn 可用性群組,但是不會重新啟動執行個體。在您手動重新啟動此伺服器執行個體之前,變更將不會生效。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Enable-SqlAlwaysOn</command:name><maml:description><maml:para>在 Path、InputObject 或 ServerInstance 參數所指定的 SQL Server 執行個體上啟用 AlwaysOn 可用性群組功能。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Enable</command:verb><command:noun>SqlAlwaysOn</command:noun><dev:version /></command:details><maml:description><maml:para>Enable-SqlAlwaysOn Cmdlet 會在 SQL Server 執行個體上啟用 AlwaysOn。如果您在 SQL Server 服務執行時啟用 AlwaysOn 可用性群組,就必須重新啟動 Database Engine 服務,才能完成變更。除非您指定 -Force 參數,否則此 Cmdlet 會詢問您是否想要重新啟動服務。如果取消,就不會進行任何作業。 </maml:para><maml:para>如果 AlwaysOn 可用性群組已經啟用,這個 Cmdlet 就不會執行任何動作。 </maml:para><maml:para>這個 Cmdlet 可以針對遠端服務執行。您必須擁有系統管理員權限,才能執行這個 Cmdlet。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Enable-SqlAlwaysOn</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>您想要啟用 AlwaysOn 之 SQL Server 執行個體的名稱。此格式應該是 MACHINENAME\INSTANCE。可搭配 -Credential 參數一起使用,以變更遠端伺服器的 AlwaysOn 設定。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Force</maml:name><maml:description><maml:para>指定 -Force,即可強制 Cmdlet 在未經使用者確認的情況下繼續進行。提供此參數的目的是要讓您建構指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>系統不會提示使用者重新啟動 SQL Server 服務。您必須手動重新啟動 SQL Server 服務,才能讓變更生效。設定此參數時,系統會忽略 -Force。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Enable-SqlAlwaysOn</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該啟用 AlwaysOn 可用性群組設定之 SQL Server 執行個體的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Server</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>您想要啟用 AlwaysOn 之 SQL Server 執行個體的名稱。此格式應該是 MACHINENAME\INSTANCE。可搭配 -Credential 參數一起使用,以變更遠端伺服器的 AlwaysOn 設定。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Force</maml:name><maml:description><maml:para>指定 -Force,即可強制 Cmdlet 在未經使用者確認的情況下繼續進行。提供此參數的目的是要讓您建構指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>系統不會提示使用者重新啟動 SQL Server 服務。您必須手動重新啟動 SQL Server 服務,才能讓變更生效。設定此參數時,系統會忽略 -Force。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Enable-SqlAlwaysOn</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>您想要啟用 AlwaysOn 之 SQL Server 執行個體的名稱。此格式應該是 MACHINENAME\INSTANCE。可搭配 -Credential 參數一起使用,以變更遠端伺服器的 AlwaysOn 設定。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Force</maml:name><maml:description><maml:para>指定 -Force,即可強制 Cmdlet 在未經使用者確認的情況下繼續進行。提供此參數的目的是要讓您建構指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>系統不會提示使用者重新啟動 SQL Server 服務。您必須手動重新啟動 SQL Server 服務,才能讓變更生效。設定此參數時,系統會忽略 -Force。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>要啟用 AlwaysOn 之 SQL Server 執行個體的名稱。此格式應該是 MACHINENAME\INSTANCE。可搭配 -Credential 參數使用,以變更遠端伺服器的 AlwaysOn 設定。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>您想要啟用 AlwaysOn 之 SQL Server 執行個體的名稱。此格式應該是 MACHINENAME\INSTANCE。可搭配 -Credential 參數一起使用,以變更遠端伺服器的 AlwaysOn 設定。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue><dev:type><maml:name>PSCredential</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Force</maml:name><maml:description><maml:para>指定 -Force,即可強制 Cmdlet 在未經使用者確認的情況下繼續進行。提供此參數的目的是要讓您建構指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該啟用 AlwaysOn 可用性群組設定之 SQL Server 執行個體的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Server</command:parameterValue><dev:type><maml:name>Server</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>系統不會提示使用者重新啟動 SQL Server 服務。您必須手動重新啟動 SQL Server 服務,才能讓變更生效。設定此參數時,系統會忽略 -Force。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>False</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>要啟用 AlwaysOn 之 SQL Server 執行個體的名稱。此格式應該是 MACHINENAME\INSTANCE。可搭配 -Credential 參數使用,以變更遠端伺服器的 AlwaysOn 設定。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 參考應該啟用 AlwaysOn 之 SQL Server 執行個體的 SMO.Server 物件。 </maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Enable-SqlAlwaysOn -Path SQLSERVER:\Sql\Computer\Instance </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在位於指定路徑的 SQL Server 執行個體上啟用 AlwaysOn 可用性群組。這項變更需要重新啟動執行個體,而且系統將提示您確認重新啟動。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Enable-SqlAlwaysOn -Path SQLSERVER:\Sql\Computer\Instance -Force </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在位於指定路徑的 SQL Server 執行個體上啟用 AlwaysOn 可用性群組。-Force 選項會導致伺服器執行個體在不提示您確認的情況下重新啟動。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Enable-SqlAlwaysOn -ServerInstance Computer\Instance </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在名為 'Computer\Instance' 的 SQL Server 執行個體上啟用 AlwaysOn 可用性群組。這項變更需要重新啟動執行個體,而且系統將提示您確認重新啟動。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 4 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Enable-SqlAlwaysOn -ServerInstance Computer\Instance -Credential (Get-Credential DOMAIN\Username) </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會使用 Windows 驗證,在名為 'Computer\Instance' 的 SQL Server 執行個體上啟用 AlwaysOn 可用性群組。系統將提示您輸入指定帳戶的密碼。這項變更需要重新啟動執行個體,而且系統也將提示您確認重新啟動。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 5 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Enable-SqlAlwaysOn -Path SQLSERVER:\Sql\Computer\Instance -NoServiceRestart </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在位於指定路徑的 SQL Server 執行個體上啟用 AlwaysOn 可用性群組,但是不會重新啟動執行個體。在您手動重新啟動此伺服器執行個體之前,變更將不會生效。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Get-SqlCredential</command:name><maml:description><maml:para>傳回 SQL 認證物件。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Get</command:verb><command:noun>SqlCredential</command:noun><dev:version /></command:details><maml:description><maml:para>Get-SqlCredential 會傳回 SQL 認證物件。 </maml:para><maml:para>這個 Cmdlet 支援下列作業模式,傳回 SQL 認證名稱: 1.藉由指定 SQL 認證的名稱和執行個體的路徑。 2.藉由指定 SQL Credential 和伺服器物件的名稱。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Get-SqlCredential</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>認證的名稱 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值會使用目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Get-SqlCredential</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>認證的名稱 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>認證所在的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>認證所在的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue><dev:type><maml:name>Context</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>認證的名稱 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值會使用目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Get-SqlCredential –Name "mycredential" </dev:code><dev:remarks><maml:para>此命令會傳回認證物件。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\> </dev:code><dev:remarks></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Get-SqlDatabase</command:name><maml:description><maml:para>針對存在於目標 SQL Server 執行個體中的每個資料庫,傳回 SQL Database 物件。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Get</command:verb><command:noun>SqlDatabase</command:noun><dev:version /></command:details><maml:description><maml:para>針對存在於目標 SQL Server 執行個體中的每個資料庫,傳回 SQL Database 物件。如果提供資料庫名稱,則此 Cmdlet 僅會傳回該特定資料庫物件。</maml:para><maml:para>這個 Cmdlet 支援下列傳回 SQL Database 物件的作業模式:</maml:para><maml:para>1.透過指定執行個體 PowerShell 路徑。</maml:para><maml:para>2.透過指定伺服器物件。</maml:para><maml:para>3.透過指定目標 SQL Server 執行個體的 ServerInstance。</maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Get-SqlDatabase</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>要擷取的資料庫名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>產生執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Get-SqlDatabase</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>要擷取的資料庫名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="3" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>此參數可指定將成為作業目標之 SQL Server 執行個體的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionTimeout</maml:name><maml:description><maml:para>在逾時失敗之前要等候 SQL Server 連線的秒數。逾時值必須是介於 0 到 65534 之間的整數。如果指定了 0,連線嘗試就不會逾時。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>產生執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Get-SqlDatabase</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>要擷取的資料庫名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>目標執行個體的伺服器物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>產生執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionTimeout</maml:name><maml:description><maml:para>在逾時失敗之前要等候 SQL Server 連線的秒數。逾時值必須是介於 0 到 65534 之間的整數。如果指定了 0,連線嘗試就不會逾時。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue><dev:type><maml:name>PSCredential</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>目標執行個體的伺服器物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue><dev:type><maml:name>Context</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>要擷取的資料庫名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>產生執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="3" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>此參數可指定將成為作業目標之 SQL Server 執行個體的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>CD SQLSERVER:\SQL\Computer\Instance; Get-SqlDatabase -Name "DbName" -Credential $sqlCredential; </dev:code><dev:remarks><maml:para>此命令會針對伺服器執行個體 'Computer\Instance' 的 'DbName' 資料庫,傳回資料庫物件。目前的工作目錄會用來決定應該進行作業的伺服器執行個體。</maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>This command retrieves all instances of SQL Server on the machine ‘MachineName’ and returns all the databases that are present in the instances. PS C:\>Get-SqlInstance -Credential $credential -MachineName " MachineName" | Get-SqlDatabase -Credential $sqlCredential; </dev:code><dev:remarks><maml:para></maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>Online Version:</maml:linkText><maml:uri></maml:uri></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Get-SqlInstance</command:name><maml:description><maml:para>針對存在於目標電腦中的每個 SQL Server 執行個體,傳回 SQL 執行個體物件。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Get</command:verb><command:noun>SqlInstance</command:noun><dev:version /></command:details><maml:description><maml:para>針對存在於目標電腦中的每個 SQL Server 執行個體,傳回 SQL 執行個體物件。如果提供 SQL Server 執行個體名稱,此 Cmdlet 僅會傳回該特定 SQL Server 執行個體。</maml:para><maml:para>SQL Server 雲端配接器必須在主控 SQL Server 執行個體的電腦上執行及存取。</maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Get-SqlInstance</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>MachineName</maml:name><maml:description><maml:para>目標電腦的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>當您想擷取目標電腦上的特定 SQL Server 執行個體時,SQL Server 執行個體的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue><dev:type><maml:name>PSCredential</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>MachineName</maml:name><maml:description><maml:para>目標電腦的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>當您想擷取目標電腦上的特定 SQL Server 執行個體時,SQL Server 執行個體的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>Get-SqlInstance -Credential $credential -MachineName " MachineName" -Name "InstanceName" -AcceptSelfSignedCertificate; </dev:code><dev:remarks><maml:para>此命令會擷取 'MachineName' 電腦上的 SQL Server 執行個體 'InstanceName'。系統會自動接受目標電腦的自我簽署憑證,而不提示使用者。</maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>This command retrieves all instances of SQL Server on the machine ‘MachineName’. The self-signed certificate of the target machine will be automatically accepted without prompting the user. PS C:\>Get-SqlInstance -Credential $credential -MachineName "MachineName" -AcceptSelfSignedCertificate; </dev:code><dev:remarks><maml:para></maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>Online Version:</maml:linkText><maml:uri></maml:uri></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Get-SqlSmartAdmin</command:name><maml:description><maml:para>取得或擷取 SQL Smart Admin 物件及其屬性。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Get</command:verb><command:noun>SqlSmartAdmin</command:noun><dev:version /></command:details><maml:description><maml:para>Get-SqlSmartAdmin Cmdlet 會取得 SQL Smart Admin 物件。Smart Admin 物件包括 SQL Server Managed Backup 到 Windows Azure 的組態設定。這個 Cmdlet 支援下列傳回物件的作業模式: 1 使用 –name 參數傳遞伺服器執行個體的名稱。若是預設執行個體,僅指定電腦名稱即可。若是具名執行個體,請使用 'computername\instancename'。 2.傳遞 SQL Server 執行個體到 -Path 參數的路徑。</maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Get-SqlSmartAdmin</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值會設為目前的工作位置。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>SQL Server 執行個體名稱的格式為:'Computer\Instance'</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>SQL Server 執行個體的名稱。若是預設執行個體,只要指定電腦名稱:"MyComputer"。若是具名執行個體,請使用 "ComputerName\InstanceName" 這樣的格式。–name 參數和 –ServerInstance 都可以指定執行個體的名稱,但 –ServerInstance 也可接受伺服器執行個體名稱的管線輸入,或 SqInstanceInfo 物件。可使用 Get-SqlInstances Cmdlet 擷取 SqlInstanceInfo 物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Get-SqlSmartAdmin</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>Server 物件的執行個體</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>SQL Server 執行個體名稱的格式為:'Computer\Instance'</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>SQL Server 執行個體的名稱。若是預設執行個體,只要指定電腦名稱:"MyComputer"。若是具名執行個體,請使用 "ComputerName\InstanceName" 這樣的格式。–name 參數和 –ServerInstance 都可以指定執行個體的名稱,但 –ServerInstance 也可接受伺服器執行個體名稱的管線輸入,或 SqInstanceInfo 物件。可使用 Get-SqlInstances Cmdlet 擷取 SqlInstanceInfo 物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Get-SqlSmartAdmin</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>SQL Server 執行個體名稱的格式為:'Computer\Instance'</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>SQL Server 執行個體的名稱。若是預設執行個體,只要指定電腦名稱:"MyComputer"。若是具名執行個體,請使用 "ComputerName\InstanceName" 這樣的格式。–name 參數和 –ServerInstance 都可以指定執行個體的名稱,但 –ServerInstance 也可接受伺服器執行個體名稱的管線輸入,或 SqInstanceInfo 物件。可使用 Get-SqlInstances Cmdlet 擷取 SqlInstanceInfo 物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>Server 物件的執行個體</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue><dev:type><maml:name>Context</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>SQL Server 執行個體名稱的格式為:'Computer\Instance'</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值會設為目前的工作位置。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>SQL Server 執行個體的名稱。若是預設執行個體,只要指定電腦名稱:"MyComputer"。若是具名執行個體,請使用 "ComputerName\InstanceName" 這樣的格式。–name 參數和 –ServerInstance 都可以指定執行個體的名稱,但 –ServerInstance 也可接受伺服器執行個體名稱的管線輸入,或 SqInstanceInfo 物件。可使用 Get-SqlInstances Cmdlet 擷取 SqlInstanceInfo 物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue><dev:type><maml:name>PSObject</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\ PS> cd SQLSERVER:\SQL\Computer\MyInstance Get-SqlSmartAdmin Following is a list of the properties returned by the above command : BackupEnabled : Shows whether backup is enabled at the instance level. BackupRetentionPeriodInDays: Displays the number of days for retaining backup files. CredentialName: Name of the SQL Credential used to authenticate to the Windows Azure storage account. MasterSwitch: Shows whether the master switch is turned on or off. Parent: Name of the instance of SQL Server. Urn: The path of the Smart Admin object. Properties: list of all the properties including the above. </dev:code><dev:remarks><maml:para>此命令會擷取具名 SQL Server 執行個體 'MyInstance' 的 smart admin 物件屬性。</maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>Get-SqlSmartAdmin -name “computer\MyInstance” </dev:code><dev:remarks><maml:para>此命令會使用 -serverName 參數擷取 smart admin 物件屬性。</maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>Online Version:</maml:linkText><maml:uri></maml:uri></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Invoke-PolicyEvaluation</command:name><maml:description><maml:para>針對目標集評估一個或多個 SQL Server 原則式管理原則,並報告此集合的符合層級,或讓此集合符合原則。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Invoke</command:verb><command:noun>PolicyEvaluation</command:noun><dev:version /></command:details><maml:description><maml:para>針對名為目標集的一組 SQL Server 物件評估一個或多個原則式管理原則。這些原則會指定與 SQL Server 物件相關聯之各種屬性的允許值,例如建立資料庫名稱或定序的網站標準。當 Invoke-PolicyEvaluation 以 Check 模式執行時,它會報告目標集中物件的目前屬性是否符合原則定義中的規則。如果目標集中物件的屬性不符合原則,就不會重新設定這些物件。在 Configure 模式中,Invoke-PolicyEvaluation 會重新設定目標集中不符合原則定義的任何物件。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Invoke-PolicyEvaluation</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="1" aliases=""><maml:name>Policy</maml:name><maml:description><maml:para>指定一個或多個要評估的原則。原則可以儲存在 SQL Server Database Engine 的執行個體中,也可以儲存成匯出的 XML 檔案。若為儲存在 Database Engine 執行個體中的原則,請使用以 SQLSERVER:\SQLPolicy 資料夾為基礎的路徑來指定原則的位置。若為儲存成 XML 檔案的原則,請使用檔案系統路徑來指定原則的位置。 </maml:para><maml:para>-Policy 可以接受指定一個或多個要評估之原則名稱的字串。如果字串中僅指定了檔案或原則名稱,Invoke-PolicyEvaluation 就會使用目前路徑的設定。若為儲存在 Database Engine 執行個體中的原則,請使用原則名稱,例如 "Database Status" 或 "SQLSERVER:\SQLPolicy\MyComputer\DEFAULT\Policies\Database Status"。若為匯出成 XML 檔案的原則,請使用檔案的名稱,例如 "Database Status.xml" 或 "C:\MyPolicyFolder\Database Status.xml"。 </maml:para><maml:para>-Policy 可以接受一組 FileInfo 物件,例如針對包含匯出 XML 原則之資料夾執行的 Get-ChildItem Cmdlet 傳送輸出。-Policy 也可以接受一組 Policy 物件,例如針對 SQLSERVER:\SQLPolicy 路徑執行之 Get-ChildItem 的傳送輸出。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AdHocPolicyEvaluationMode</maml:name><maml:description><maml:para>指定 Invoke-PolicyEvaluation 只報告目標集的符合狀態 (Check),還是也會將目標集重新設定為符合原則 (Configure)。 </maml:para><maml:para>Check - 使用登入帳戶的認證來報告目標集的符合狀態,但不重新設定任何物件。 </maml:para><maml:para>CheckSqlScriptAsProxy - 使用 ##MS_PolicyTSQLExecutionLogin## Proxy 帳戶認證來執行檢查報表。 </maml:para><maml:para>Configure - 重新設定不符合原則的目標集物件,並且報告結果狀態。Invoke-PolicyEvaluation 只會重新設定可設定且具決定性的屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AdHocPolicyEvaluationMode</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>OutputXml</maml:name><maml:description><maml:para>指定 Invoke-PolicyEvaluation Cmdlet 會使用「服務模組化語言交換格式」(Service Modeling Language Interchange Format,SML-IF) 結構描述來產生 XML 格式的報表。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>TargetExpression</maml:name><maml:description><maml:para>指定傳回定義目標集之物件清單的查詢。這些查詢會指定為節點以 '/' 字元分隔的字串。每個節點的格式都是 ObjectType[Filter]。ObjectType 是 SQL Server 管理物件 (SMO) 物件模型的其中一個物件,而 Filter 是針對位於該節點之特定物件進行篩選的運算式。這些節點必須遵循 SMO 物件的階層。例如,下列查詢運算式會傳回 AdventureWorks 範例資料庫:"Server[@Name='MyComputer']/Database[@Name='AdventureWorks']"。 </maml:para><maml:para>如果已指定 -TargetExpression,請勿指定 -TargetObject。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>TargetServerName</maml:name><maml:description><maml:para>指定包含目標集的 Database Engine 執行個體。您可以指定包含 Microsoft.SqlServer.Management.Sfc.Sdk.SQLStoreConnection 物件的變數。您也可以指定符合 System.Data.SqlClient.SQLConnection 類別之 ConnectionString 屬性所使用之規則的字串。這些字串包括使用 System.Data.SqlClient.SqlConnectionStringBuilder 類別所建立的字串。根據預設,Invoke-PolicyEvaluation 會使用 Windows 驗證來連接。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Invoke-PolicyEvaluation</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="1" aliases=""><maml:name>Policy</maml:name><maml:description><maml:para>指定一個或多個要評估的原則。原則可以儲存在 SQL Server Database Engine 的執行個體中,也可以儲存成匯出的 XML 檔案。若為儲存在 Database Engine 執行個體中的原則,請使用以 SQLSERVER:\SQLPolicy 資料夾為基礎的路徑來指定原則的位置。若為儲存成 XML 檔案的原則,請使用檔案系統路徑來指定原則的位置。 </maml:para><maml:para>-Policy 可以接受指定一個或多個要評估之原則名稱的字串。如果字串中僅指定了檔案或原則名稱,Invoke-PolicyEvaluation 就會使用目前路徑的設定。若為儲存在 Database Engine 執行個體中的原則,請使用原則名稱,例如 "Database Status" 或 "SQLSERVER:\SQLPolicy\MyComputer\DEFAULT\Policies\Database Status"。若為匯出成 XML 檔案的原則,請使用檔案的名稱,例如 "Database Status.xml" 或 "C:\MyPolicyFolder\Database Status.xml"。 </maml:para><maml:para>-Policy 可以接受一組 FileInfo 物件,例如針對包含匯出 XML 原則之資料夾執行的 Get-ChildItem Cmdlet 傳送輸出。-Policy 也可以接受一組 Policy 物件,例如針對 SQLSERVER:\SQLPolicy 路徑執行之 Get-ChildItem 的傳送輸出。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AdHocPolicyEvaluationMode</maml:name><maml:description><maml:para>指定 Invoke-PolicyEvaluation 只報告目標集的符合狀態 (Check),還是也會將目標集重新設定為符合原則 (Configure)。 </maml:para><maml:para>Check - 使用登入帳戶的認證來報告目標集的符合狀態,但不重新設定任何物件。 </maml:para><maml:para>CheckSqlScriptAsProxy - 使用 ##MS_PolicyTSQLExecutionLogin## Proxy 帳戶認證來執行檢查報表。 </maml:para><maml:para>Configure - 重新設定不符合原則的目標集物件,並且報告結果狀態。Invoke-PolicyEvaluation 只會重新設定可設定且具決定性的屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AdHocPolicyEvaluationMode</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>OutputXml</maml:name><maml:description><maml:para>指定 Invoke-PolicyEvaluation Cmdlet 會使用「服務模組化語言交換格式」(Service Modeling Language Interchange Format,SML-IF) 結構描述來產生 XML 格式的報表。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>TargetObjects</maml:name><maml:description><maml:para>指定一個 PSObject 或 PSObject 的陣列,其中定義要據以評估原則的 SQL Server 物件集。若要連接到 SQL Server Analysis Services 的執行個體,請針對 -TargetObject 指定 Microsoft.AnalysisServices.Server 物件。 </maml:para><maml:para>如果已指定 -TargetObject,請勿指定 -TargetExpression。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">PSObject[]</command:parameterValue></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AdHocPolicyEvaluationMode</maml:name><maml:description><maml:para>指定 Invoke-PolicyEvaluation 只報告目標集的符合狀態 (Check),還是也會將目標集重新設定為符合原則 (Configure)。 </maml:para><maml:para>Check - 使用登入帳戶的認證來報告目標集的符合狀態,但不重新設定任何物件。 </maml:para><maml:para>CheckSqlScriptAsProxy - 使用 ##MS_PolicyTSQLExecutionLogin## Proxy 帳戶認證來執行檢查報表。 </maml:para><maml:para>Configure - 重新設定不符合原則的目標集物件,並且報告結果狀態。Invoke-PolicyEvaluation 只會重新設定可設定且具決定性的屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AdHocPolicyEvaluationMode</command:parameterValue><dev:type><maml:name>AdHocPolicyEvaluationMode</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>OutputXml</maml:name><maml:description><maml:para>指定 Invoke-PolicyEvaluation Cmdlet 會使用「服務模組化語言交換格式」(Service Modeling Language Interchange Format,SML-IF) 結構描述來產生 XML 格式的報表。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="1" aliases=""><maml:name>Policy</maml:name><maml:description><maml:para>指定一個或多個要評估的原則。原則可以儲存在 SQL Server Database Engine 的執行個體中,也可以儲存成匯出的 XML 檔案。若為儲存在 Database Engine 執行個體中的原則,請使用以 SQLSERVER:\SQLPolicy 資料夾為基礎的路徑來指定原則的位置。若為儲存成 XML 檔案的原則,請使用檔案系統路徑來指定原則的位置。 </maml:para><maml:para>-Policy 可以接受指定一個或多個要評估之原則名稱的字串。如果字串中僅指定了檔案或原則名稱,Invoke-PolicyEvaluation 就會使用目前路徑的設定。若為儲存在 Database Engine 執行個體中的原則,請使用原則名稱,例如 "Database Status" 或 "SQLSERVER:\SQLPolicy\MyComputer\DEFAULT\Policies\Database Status"。若為匯出成 XML 檔案的原則,請使用檔案的名稱,例如 "Database Status.xml" 或 "C:\MyPolicyFolder\Database Status.xml"。 </maml:para><maml:para>-Policy 可以接受一組 FileInfo 物件,例如針對包含匯出 XML 原則之資料夾執行的 Get-ChildItem Cmdlet 傳送輸出。-Policy 也可以接受一組 Policy 物件,例如針對 SQLSERVER:\SQLPolicy 路徑執行之 Get-ChildItem 的傳送輸出。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue><dev:type><maml:name>PSObject</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>TargetExpression</maml:name><maml:description><maml:para>指定傳回定義目標集之物件清單的查詢。這些查詢會指定為節點以 '/' 字元分隔的字串。每個節點的格式都是 ObjectType[Filter]。ObjectType 是 SQL Server 管理物件 (SMO) 物件模型的其中一個物件,而 Filter 是針對位於該節點之特定物件進行篩選的運算式。這些節點必須遵循 SMO 物件的階層。例如,下列查詢運算式會傳回 AdventureWorks 範例資料庫:"Server[@Name='MyComputer']/Database[@Name='AdventureWorks']"。 </maml:para><maml:para>如果已指定 -TargetExpression,請勿指定 -TargetObject。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>TargetObjects</maml:name><maml:description><maml:para>指定一個 PSObject 或 PSObject 的陣列,其中定義要據以評估原則的 SQL Server 物件集。若要連接到 SQL Server Analysis Services 的執行個體,請針對 -TargetObject 指定 Microsoft.AnalysisServices.Server 物件。 </maml:para><maml:para>如果已指定 -TargetObject,請勿指定 -TargetExpression。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">PSObject[]</command:parameterValue><dev:type><maml:name>PSObject[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>TargetServerName</maml:name><maml:description><maml:para>指定包含目標集的 Database Engine 執行個體。您可以指定包含 Microsoft.SqlServer.Management.Sfc.Sdk.SQLStoreConnection 物件的變數。您也可以指定符合 System.Data.SqlClient.SQLConnection 類別之 ConnectionString 屬性所使用之規則的字串。這些字串包括使用 System.Data.SqlClient.SqlConnectionStringBuilder 類別所建立的字串。根據預設,Invoke-PolicyEvaluation 會使用 Windows 驗證來連接。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue><dev:type><maml:name>PSObject</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>sl "C:\Program Files (x86)\Microsoft SQL Server" sl "%PRODUCTVERSION%\Tools\Policies\DatabaseEngine\1033" Invoke-PolicyEvaluation -Policy "Trustworthy Database.xml" -TargetServer "MYCOMPUTER" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>針對指定電腦的預設執行個體評估原則。您可以從 XML 檔案讀取原則並且使用 Windows 驗證來連接。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>sl "C:\Program Files (x86)\Microsoft SQL Server" sl "%PRODUCTVERSION%\Tools\Policies\DatabaseEngine\1033" gci "Database Status.xml", "Trustworthy Database.xml" | Invoke-PolicyEvaluation -TargetServer "MYCOMPUTER" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>使用 Get-Childitem,從資料夾中的 XML 檔案讀取兩個原則,然後將它們傳送至 Invoke-PolicyEvaluation。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>sl "C:\Program Files (x86)\Microsoft SQL Server" sl "%PRODUCTVERSION%\Tools\Policies\DatabaseEngine\1033" Invoke-PolicyEvaluation -Policy "Database Status.xml" -TargetServer "MYCOMPUTER" -OutputXML > C:\MyReportFolder\MyReport.xml </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>使用「服務模組化語言交換格式」(Services Modeling Language Interchange Format,SML-IF) 結構描述來格式化原則評估的輸出,然後將輸出重新導向至檔案。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 4 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>sl SQLSERVER:\SQLPolicy\MYCOMPUTER\DEFAULT\Policies gci | Where-Object { $_.PolicyCategory -eq "Microsoft Best Practices: Maintenance" } | Invoke-PolicyEvaluation -TargetServer "MYCOMPUTER" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>設定 SQL Server 原則存放區的目前路徑。您可以使用 Get-ChildItem 來讀取所有原則,並且使用 Where-Object 針對 PolicyCategory 屬性設定為 "Microsoft Best Practices: Maintenance" 的原則進行篩選。然後,將篩選的原則集傳送至 Invoke-PolicyEvaluation。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 5 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>sl "C:\Program Files (x86)\Microsoft SQL Server" sl "%PRODUCTVERSION%\Tools\Policies\DatabaseEngine\1033" $conn = New-Object Microsoft.SqlServer.Management.Sdk.Sfc.SqlStoreConnection("server='MYCOMPUTER';Trusted_Connection=True") Invoke-PolicyEvaluation -Policy "Database Status.xml" -TargetServer $conn </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>如何使用 Sfc.SqlStoreConnection 物件來指定目標伺服器。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 6 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>sl "C:\Program Files (x86)\Microsoft SQL Server\%PRODUCTVERSION%" sl "tools\Policies\analysisservices\1033" [System.Reflection.Assembly]::LoadWithPartialName("Microsoft.AnalysisServices") $SSASsvr = new-object Microsoft.AnalysisServices.Server $SSASsvr.Connect("Data Source=localhost") Invoke-PolicyEvaluation 'Surface Area Configuration for Analysis Services Features.xml' -TargetObject $SSASsvr </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>如何載入 SQL Server Analysis Services 組件,然後建立本機電腦上預設執行個體的連接,並且執行 Analysis Services 介面區組態原則。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 7 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>sl "C:\Program Files (x86)\Microsoft SQL Server" sl "120\Tools\Policies\DatabaseEngine\1033" Invoke-PolicyEvaluation "Database Status.xml" -TargetServer "MYCOMPUTER" -TargetExpression "Server[@Name='MYCOMPUTER']/Database[@Name='AdventureWorks2014']" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>使用 -TargetExpression 查詢運算式來指定針對 AdventureWorks2014 範例資料庫評估 Database Status 原則。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 8 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>sl "C:\Program Files (x86)\Microsoft SQL Server\120\Tools\Policies\ReportingServices\1033" [System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SqlServer.Dmf.Adapters") $SSRSsvr = new-object Microsoft.SqlServer.Management.Adapters.RSContainer('MyComputer') Invoke-PolicyEvaluation -Policy "Surface Area Configuration for Reporting Services 2008 Features.xml" -TargetObject $SSRSsvr </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>如何載入 SQL Server Reporting Services 組件,然後建立本機電腦上預設執行個體的連接,並且執行 Reporting Services 介面區組態原則。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>SQL Server Books Online: Using the Invoke-PolicyEvaluation cmdlet</maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Invoke-Sqlcmd</command:name><maml:description><maml:para>執行內含陳述式來自 SQL Server sqlcmd 公用程式所支援之語言 (Transact-SQL 和 XQuery) 與命令的指令碼。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Invoke</command:verb><command:noun>Sqlcmd</command:noun><dev:version /></command:details><maml:description><maml:para>執行包含 SQL Server sqlcmd 公用程式所支援之語言與命令的指令碼。支援的語言為 Transact-SQL 以及 Database Engine 所支援的 XQuery 語法。Invoke-Sqlcmd 也接受 sqlcmd 所支援的許多命令,例如 GO 和 QUIT。Invoke-Sqlcmd 可接受 sqlcmd 指令碼變數,例如 SQLCMDUSER。根據預設,Invoke-Sqlcmd 不會設定 sqlcmd 指令碼變數。 </maml:para><maml:para>Invoke-Sqlcmd 不支援主要與互動式指令碼編輯有關的 sqlcmd 命令。不支援的命令包括 :!!、:connect、:error、:out、:ed、:list、:listvar、:reset、:perftrace 和 :serverlist。 </maml:para><maml:para>指令碼傳回的第一個結果集會顯示成格式化資料表。如果第一個結果集之後的其他結果集與第一個結果集具有不同的資料行清單,則不會顯示這些結果集。如果第一個結果集之後的其他結果集具有相同的資料行清單,其資料列就會附加至包含第一個結果集所傳回之資料列的格式化資料表。 </maml:para><maml:para>除非您使用 PowerShell -Verbose 參數,否則 Invoke-Sqlcmd 不會傳回 SQL Server 訊息輸出,例如 PRINT 陳述式的輸出。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Invoke-Sqlcmd</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Query</maml:name><maml:description><maml:para>指定一個或多個要執行的查詢。這些查詢可以是 Transact-SQL 或 XQuery 陳述式,或是 sqlcmd 命令。您可以指定多個以分號隔開的查詢。請勿指定 sqlcmd GO 分隔符號。請逸出字串中包含的任何雙引號。您可以考慮使用括號識別碼 (例如 [MyTable]) 而非引號識別碼 (例如 "MyTable")。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AbortOnError</maml:name><maml:description><maml:para>指定如果 Invoke-Sqlcmd 遇到錯誤,Invoke-Sqlcmd 就會停止執行並將錯誤層級傳回給 PowerShell ERRORLEVEL 變數。如果錯誤的嚴重性高於 10,傳回的錯誤層級就是 1;如果錯誤的嚴重性為 10 以下,錯誤層級則為 0。如果同時指定了 -ErrorLevel,只有當錯誤訊息嚴重性也等於或高於針對 -ErrorLevel 指定的值時,Invoke-Sqlcmd 才會傳回 1。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionTimeout</maml:name><maml:description><maml:para>指定如果 Invoke-Sqlcmd 無法成功連接到 Database Engine 的執行個體,則 Invoke-Sqlcmd 逾時的秒數。逾時值必須是介於 0 到 65534 之間的整數。如果指定了 0,連接嘗試就不會逾時。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>指定資料庫名稱的字元字串。Invoke-Sqlcmd 會連接到 -ServerInstance 中指定之執行個體內的這個資料庫。 </maml:para><maml:para>如果未指定 -Database,使用的資料庫就會取決於目前路徑是否同時指定 SQLSERVER:\SQL 資料夾和資料庫名稱。如果路徑同時指定了 SQL 資料夾和資料庫名稱,Invoke-Sqlcmd 就會連接到路徑中指定的資料庫。如果路徑不是以 SQL 資料夾為基礎,或者路徑不包含資料庫名稱,Invoke-Sqlcmd 就會連接到目前登入識別碼的預設資料庫。如果您指定了 -IgnoreProviderContext 參數,Invoke-Sqlcmd 就不會考慮目前路徑中指定的任何資料庫,而是連接到目前登入識別碼所定義的預設資料庫。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DedicatedAdministratorConnection</maml:name><maml:description><maml:para>使用專用管理員連接 (DAC) 來連接到 Database Engine 的執行個體。DAC 可讓系統管理員用來進行一些動作,例如疑難排解不接受新標準連接的執行個體。此執行個體必須設定為支援 DAC。如果未啟用 DAC,Invoke-Sqlcmd 就會報告錯誤並停止執行。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DisableCommands</maml:name><maml:description><maml:para>在批次檔中執行時,關閉可能危及安全性的一些 sqlcmd 功能。它會防止 PowerShell 變數傳入至 Invoke-Sqlcmd 指令碼。SQLCMDINI 指令碼變數中指定的啟動指令碼不會執行。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DisableVariables</maml:name><maml:description><maml:para>指定 Invoke-Sqlcmd 會忽略 sqlcmd 指令碼變數。當指令碼所包含的許多 INSERT 陳述式可能含有與變數 (例如 $(variable_name)) 相同格式的字串時,這就很有用。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptConnection</maml:name><maml:description><maml:para>指定 Invoke-Sqlcmd 是否會使用安全通訊端層 (SSL) 加密來連接到 -ServerInstance 中指定的 Database Engine 執行個體。如果指定了 TRUE,就會使用 SSL 加密。如果指定了 FALSE,就不會使用加密。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ErrorLevel</maml:name><maml:description><maml:para>指定 Invoke-Sqlcmd 只會顯示嚴重性層級等於或高於指定值的錯誤訊息。如果未指定 -ErrorLevel 或設定為 0,則會顯示所有錯誤訊息。Database Engine 錯誤嚴重性的範圍介於 1 到 24 之間。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>HostName</maml:name><maml:description><maml:para>指定工作站名稱。工作站名稱是由 sp_who 系統預存程序所回報,而且位於 sys.processes 目錄檢視的 hostname 資料行中。如果未指定 HostName,預設值就是執行 Invoke-Sqlcmd 的電腦名稱。HostName 可用來識別不同的 Invoke-Sqlcmd 工作階段。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>IgnoreProviderContext</maml:name><maml:description><maml:para>Invoke-Sqlcmd 會忽略目前 SQLSERVER:\SQL 路徑所建立的資料庫內容。如果未指定 -Database 參數,Invoke-Sqlcmd 就會使用目前登入識別碼或 Windows 帳戶的預設資料庫。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>IncludeSqlUserErrors</maml:name><maml:description><maml:para>會導向 Invoke-Sqlcmd 以傳回預設在其他情況下忽略的 SQL 使用者指令碼錯誤。如果指定這個參數,Invoke-Sqlcmd 會符合 sqlcmd 公用程式的預設行為。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>InputFile</maml:name><maml:description><maml:para>指定要當做 Invoke-Sqlcmd 之查詢輸入使用的檔案。此檔案可以包含 Transact-SQL 陳述式、XQuery 陳述式以及 sqlcmd 命令和指令碼變數。請指定檔案的完整路徑。檔案路徑或檔案名稱中不允許使用空格。 </maml:para><maml:para>建議您只執行來自信任來源的指令碼。請利用適當的 NTFS 權限來確保所有輸入指令碼的安全。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxBinaryLength</maml:name><maml:description><maml:para>指定針對具有二進位字串資料類型 (例如 binary 和 varbinary) 之資料行傳回的最大位元組數目。預設值是 1,024 個位元組。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxCharLength</maml:name><maml:description><maml:para>指定針對具有字元或 Unicode 資料類型 (例如 char、nchar、varchar 和 nvarchar) 之資料行傳回的最大字元數目。預設值是 4,000 個字元。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NewPassword</maml:name><maml:description><maml:para>指定 SQL Server 驗證登入識別碼的新密碼。Invoke-Sqlcmd 會變更密碼,然後結束。此外,您也必須指定 -Username 和 -Password,其中 -Password 會指定登入的目前密碼。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>OutputSqlErrors</maml:name><maml:description><maml:para>指定錯誤訊息是否會顯示在 Invoke-Sqlcmd 輸出中。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Boolean</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Password</maml:name><maml:description><maml:para>指定 -Username 中指定之 SQL Server 驗證登入識別碼的密碼。密碼會區分大小寫。盡可能使用 Windows 驗證。請勿使用空白密碼,盡可能使用增強式密碼。如需詳細資訊,請參閱《SQL Server 線上叢書》中的<增強式密碼>。 </maml:para><maml:para>安全性注意事項:如果您輸入 -Password 後面接著密碼,任何能夠見到您的監視器的人,都能夠看見密碼。如果您在 .ps1 指令碼中編寫 -Password 後面接著密碼,任何讀取指令碼檔案的人都將看見密碼。請將適當的 NTFS 權限指派給此檔案,防止其他使用者讀取此檔案。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>QueryTimeout</maml:name><maml:description><maml:para>指定查詢逾時之前的秒數。如果沒有指定逾時值,查詢就不會逾時。逾時必須是介於 1 到 65535 之間的整數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>指定 Database Engine 執行個體名稱的字元字串或 SMO Server 物件。若是預設執行個體,只要指定電腦名稱:"MyComputer"。若是具名執行個體,請使用 "ComputerName\InstanceName" 這樣的格式。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SeverityLevel</maml:name><maml:description><maml:para>指定 Invoke-Sqlcmd 傳回給 ERRORLEVEL PowerShell 變數之錯誤訊息嚴重性層級的下限。Invoke-Sqlcmd 會從它所執行之查詢產生的錯誤訊息傳回最高嚴重性層級,但前提是嚴重性等於或高於 -SeverityLevel。如果未指定 -SeverityLevel 或設定為 0,Invoke-Sqlcmd 就會將 0 傳回給 ERRORLEVEL。Database Engine 錯誤訊息嚴重性層級的範圍介於 1 到 24 之間。Invoke-Sqlcmd 不會針對嚴重性為 10 的參考用訊息報告嚴重性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SuppressProviderContextWarning</maml:name><maml:description><maml:para>隱藏 Invoke-Sqlcmd 已使用目前 SQLSERVER:\SQL 路徑設定中之資料庫內容來建立 Cmdlet 之資料庫內容的警告。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Username</maml:name><maml:description><maml:para>指定用於建立 Database Engine 執行個體之 SQL Server 驗證連接的登入識別碼。您必須使用 -Password 來指定密碼。如果未指定 -Username 和 -Password,Invoke-Sqlcmd 就會嘗試使用執行 PowerShell 工作階段的 Windows 帳戶來進行 Windows 驗證連接。 </maml:para><maml:para>盡可能使用 Windows 驗證。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Variable</maml:name><maml:description><maml:para>建立用於 sqlcmd 指令碼的 sqlcmd 指令碼變數,並且設定變數的值。您可以使用 PowerShell 陣列來指定多個變數及其值。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AbortOnError</maml:name><maml:description><maml:para>指定如果 Invoke-Sqlcmd 遇到錯誤,Invoke-Sqlcmd 就會停止執行並將錯誤層級傳回給 PowerShell ERRORLEVEL 變數。如果錯誤的嚴重性高於 10,傳回的錯誤層級就是 1;如果錯誤的嚴重性為 10 以下,錯誤層級則為 0。如果同時指定了 -ErrorLevel,只有當錯誤訊息嚴重性也等於或高於針對 -ErrorLevel 指定的值時,Invoke-Sqlcmd 才會傳回 1。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionTimeout</maml:name><maml:description><maml:para>指定如果 Invoke-Sqlcmd 無法成功連接到 Database Engine 的執行個體,則 Invoke-Sqlcmd 逾時的秒數。逾時值必須是介於 0 到 65534 之間的整數。如果指定了 0,連接嘗試就不會逾時。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>指定資料庫名稱的字元字串。Invoke-Sqlcmd 會連接到 -ServerInstance 中指定之執行個體內的這個資料庫。 </maml:para><maml:para>如果未指定 -Database,使用的資料庫就會取決於目前路徑是否同時指定 SQLSERVER:\SQL 資料夾和資料庫名稱。如果路徑同時指定了 SQL 資料夾和資料庫名稱,Invoke-Sqlcmd 就會連接到路徑中指定的資料庫。如果路徑不是以 SQL 資料夾為基礎,或者路徑不包含資料庫名稱,Invoke-Sqlcmd 就會連接到目前登入識別碼的預設資料庫。如果您指定了 -IgnoreProviderContext 參數,Invoke-Sqlcmd 就不會考慮目前路徑中指定的任何資料庫,而是連接到目前登入識別碼所定義的預設資料庫。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DedicatedAdministratorConnection</maml:name><maml:description><maml:para>使用專用管理員連接 (DAC) 來連接到 Database Engine 的執行個體。DAC 可讓系統管理員用來進行一些動作,例如疑難排解不接受新標準連接的執行個體。此執行個體必須設定為支援 DAC。如果未啟用 DAC,Invoke-Sqlcmd 就會報告錯誤並停止執行。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DisableCommands</maml:name><maml:description><maml:para>在批次檔中執行時,關閉可能危及安全性的一些 sqlcmd 功能。它會防止 PowerShell 變數傳入至 Invoke-Sqlcmd 指令碼。SQLCMDINI 指令碼變數中指定的啟動指令碼不會執行。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DisableVariables</maml:name><maml:description><maml:para>指定 Invoke-Sqlcmd 會忽略 sqlcmd 指令碼變數。當指令碼所包含的許多 INSERT 陳述式可能含有與變數 (例如 $(variable_name)) 相同格式的字串時,這就很有用。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptConnection</maml:name><maml:description><maml:para>指定 Invoke-Sqlcmd 是否會使用安全通訊端層 (SSL) 加密來連接到 -ServerInstance 中指定的 Database Engine 執行個體。如果指定了 TRUE,就會使用 SSL 加密。如果指定了 FALSE,就不會使用加密。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ErrorLevel</maml:name><maml:description><maml:para>指定 Invoke-Sqlcmd 只會顯示嚴重性層級等於或高於指定值的錯誤訊息。如果未指定 -ErrorLevel 或設定為 0,則會顯示所有錯誤訊息。Database Engine 錯誤嚴重性的範圍介於 1 到 24 之間。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>HostName</maml:name><maml:description><maml:para>指定工作站名稱。工作站名稱是由 sp_who 系統預存程序所回報,而且位於 sys.processes 目錄檢視的 hostname 資料行中。如果未指定 HostName,預設值就是執行 Invoke-Sqlcmd 的電腦名稱。HostName 可用來識別不同的 Invoke-Sqlcmd 工作階段。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>IgnoreProviderContext</maml:name><maml:description><maml:para>Invoke-Sqlcmd 會忽略目前 SQLSERVER:\SQL 路徑所建立的資料庫內容。如果未指定 -Database 參數,Invoke-Sqlcmd 就會使用目前登入識別碼或 Windows 帳戶的預設資料庫。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>IncludeSqlUserErrors</maml:name><maml:description><maml:para>會導向 Invoke-Sqlcmd 以傳回預設在其他情況下忽略的 SQL 使用者指令碼錯誤。如果指定這個參數,Invoke-Sqlcmd 會符合 sqlcmd 公用程式的預設行為。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>InputFile</maml:name><maml:description><maml:para>指定要當做 Invoke-Sqlcmd 之查詢輸入使用的檔案。此檔案可以包含 Transact-SQL 陳述式、XQuery 陳述式以及 sqlcmd 命令和指令碼變數。請指定檔案的完整路徑。檔案路徑或檔案名稱中不允許使用空格。 </maml:para><maml:para>建議您只執行來自信任來源的指令碼。請利用適當的 NTFS 權限來確保所有輸入指令碼的安全。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxBinaryLength</maml:name><maml:description><maml:para>指定針對具有二進位字串資料類型 (例如 binary 和 varbinary) 之資料行傳回的最大位元組數目。預設值是 1,024 個位元組。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxCharLength</maml:name><maml:description><maml:para>指定針對具有字元或 Unicode 資料類型 (例如 char、nchar、varchar 和 nvarchar) 之資料行傳回的最大字元數目。預設值是 4,000 個字元。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NewPassword</maml:name><maml:description><maml:para>指定 SQL Server 驗證登入識別碼的新密碼。Invoke-Sqlcmd 會變更密碼,然後結束。此外,您也必須指定 -Username 和 -Password,其中 -Password 會指定登入的目前密碼。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>OutputSqlErrors</maml:name><maml:description><maml:para>指定錯誤訊息是否會顯示在 Invoke-Sqlcmd 輸出中。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Boolean</command:parameterValue><dev:type><maml:name>Boolean</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Password</maml:name><maml:description><maml:para>指定 -Username 中指定之 SQL Server 驗證登入識別碼的密碼。密碼會區分大小寫。盡可能使用 Windows 驗證。請勿使用空白密碼,盡可能使用增強式密碼。如需詳細資訊,請參閱《SQL Server 線上叢書》中的<增強式密碼>。 </maml:para><maml:para>安全性注意事項:如果您輸入 -Password 後面接著密碼,任何能夠見到您的監視器的人,都能夠看見密碼。如果您在 .ps1 指令碼中編寫 -Password 後面接著密碼,任何讀取指令碼檔案的人都將看見密碼。請將適當的 NTFS 權限指派給此檔案,防止其他使用者讀取此檔案。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Query</maml:name><maml:description><maml:para>指定一個或多個要執行的查詢。這些查詢可以是 Transact-SQL 或 XQuery 陳述式,或是 sqlcmd 命令。您可以指定多個以分號隔開的查詢。請勿指定 sqlcmd GO 分隔符號。請逸出字串中包含的任何雙引號。您可以考慮使用括號識別碼 (例如 [MyTable]) 而非引號識別碼 (例如 "MyTable")。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>QueryTimeout</maml:name><maml:description><maml:para>指定查詢逾時之前的秒數。如果沒有指定逾時值,查詢就不會逾時。逾時必須是介於 1 到 65535 之間的整數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>指定 Database Engine 執行個體名稱的字元字串或 SMO Server 物件。若是預設執行個體,只要指定電腦名稱:"MyComputer"。若是具名執行個體,請使用 "ComputerName\InstanceName" 這樣的格式。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue><dev:type><maml:name>PSObject</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SeverityLevel</maml:name><maml:description><maml:para>指定 Invoke-Sqlcmd 傳回給 ERRORLEVEL PowerShell 變數之錯誤訊息嚴重性層級的下限。Invoke-Sqlcmd 會從它所執行之查詢產生的錯誤訊息傳回最高嚴重性層級,但前提是嚴重性等於或高於 -SeverityLevel。如果未指定 -SeverityLevel 或設定為 0,Invoke-Sqlcmd 就會將 0 傳回給 ERRORLEVEL。Database Engine 錯誤訊息嚴重性層級的範圍介於 1 到 24 之間。Invoke-Sqlcmd 不會針對嚴重性為 10 的參考用訊息報告嚴重性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SuppressProviderContextWarning</maml:name><maml:description><maml:para>隱藏 Invoke-Sqlcmd 已使用目前 SQLSERVER:\SQL 路徑設定中之資料庫內容來建立 Cmdlet 之資料庫內容的警告。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Username</maml:name><maml:description><maml:para>指定用於建立 Database Engine 執行個體之 SQL Server 驗證連接的登入識別碼。您必須使用 -Password 來指定密碼。如果未指定 -Username 和 -Password,Invoke-Sqlcmd 就會嘗試使用執行 PowerShell 工作階段的 Windows 帳戶來進行 Windows 驗證連接。 </maml:para><maml:para>盡可能使用 Windows 驗證。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Variable</maml:name><maml:description><maml:para>建立用於 sqlcmd 指令碼的 sqlcmd 指令碼變數,並且設定變數的值。您可以使用 PowerShell 陣列來指定多個變數及其值。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>PSObject</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name>Formatted table</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Invoke-Sqlcmd -Query "SELECT GETDATE() AS TimeOfQuery;" -ServerInstance "MyComputer\MyInstance" TimeOfQuery ----------- 5/13/2010 8:49:43 PM </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會連接到電腦上的 Database Engine 具名執行個體並且執行基本 Transact-SQL 指令碼。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Invoke-Sqlcmd -InputFile "C:\MyFolder\TestSqlCmd.sql" | Out-File -filePath "C:\MyFolder\TestSqlCmd.rpt" Output sent to TestSqlCmd.rpt. </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會讀取包含 Transact-SQL 陳述式和 sqlcmd 命令的檔案、執行此檔案並且將輸出寫入另一個檔案。請利用適當的 NTFS 權限來確保所有輸出檔案的安全。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$MyArray = "MYVAR1='String1'", "MYVAR2='String2'" Invoke-Sqlcmd -Query "SELECT `$(MYVAR1) AS Var1, `$(MYVAR2) AS Var2;" -Variable $MyArray Var1 Var2 ---- ---- String1 String2 </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會使用字元字串的陣列當做 -Variable 參數的輸入。此陣列會定義多個 sqlcmd 變數。在 SELECT 陳述中,識別 sqlcmd 變數的 $ 符號會使用反勾號 (`) 字元來逸出。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 4 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-Location SQLSERVER:\SQL\MyComputer\MyInstance Invoke-Sqlcmd -Query "SELECT SERVERPROPERTY('MachineName') AS ComputerName;" -ServerInstance (Get-Item .) WARNING: Using provider context. Server = MyComputer ComputerName ------------ MyComputer </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會使用 Set-Location 來導覽至 Database Engine 執行個體的 SQL Server PowerShell 提供者路徑。然後,此範例會使用 Get-Item 來擷取 SMO Server 物件,以便當做 Invoke-Sqlcmd 的 -ServerInstance 參數使用。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 5 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Invoke-Sqlcmd -Query "PRINT N'abc'" -Verbose VERBOSE: abc </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會使用 PowerShell -Verbose 參數來傳回 PRINT 命令的訊息輸出。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 6 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-Location SQLSERVER:\SQL\MyComputer\DEFAULT\Databases\AdventureWorks2014 Invoke-Sqlcmd "SELECT DB_NAME() AS DatabaseName;" WARNING: Using provider context. Server = MyComputer, Database = AdventureWorks2014. DatabaseName ------------ AdventureWorks2014 </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會使用位置字串來提供 -Query 參數的輸入。它也會示範 Invoke-Sqlcmd 如何使用目前路徑來設定 AdventureWorks2014 的資料庫內容。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>SQL Server Books Online: Transact-SQL Reference</maml:linkText><maml:uri /></maml:navigationLink><maml:navigationLink><maml:linkText>SQL Server Books Online: sqlcmd Utility</maml:linkText><maml:uri /></maml:navigationLink><maml:navigationLink><maml:linkText>SQL Server Books Online: XQuery Reference</maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Join-SqlAvailabilityGroup</command:name><maml:description><maml:para>將 InputObject 或 Path 參數中指定的可用性複本聯結至 Name 參數所指定的可用性群組。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Join</command:verb><command:noun>SqlAvailabilityGroup</command:noun><dev:version /></command:details><maml:description><maml:para>Join-SqlAvailabilityGroup Cmdlet 會將本機次要複本聯結至 Name 參數中指定的可用性群組。這個 Cmdlet 只能在裝載尚未聯結至可用性群組之次要複本的 SQL Server 執行個體上執行。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Join-SqlAvailabilityGroup</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>可用性群組的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>裝載要聯結至可用性群組之次要複本的 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Join-SqlAvailabilityGroup</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>可用性群組的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>裝載次要複本之 SQL Server 執行個體的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Server</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>裝載次要複本之 SQL Server 執行個體的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Server</command:parameterValue><dev:type><maml:name>Server</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>可用性群組的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>裝載要聯結至可用性群組之次要複本的 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.Server</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 要聯結至可用性群組的可用性複本。 </maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><maml:alertSet><maml:title /><maml:alert><maml:para>您必須在伺服器執行個體上啟用高可用性資料復原服務,而且 Path 所指定的可用性複本必須存在。 </maml:para></maml:alert><maml:alert></maml:alert></maml:alertSet><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Join-SqlAvailabilityGroup -Path SQLSERVER:\SQL\SecondaryServer\InstanceName -Name 'MyAg' </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將位於指定路徑之伺服器執行個體所裝載的次要複本聯結至名為 'MyAg' 的可用性群組。這個伺服器執行個體必須裝載這個可用性群組中的次要複本。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Join-SqlAvailabilityGroup -Path SQLSERVER:\SQL\SecondaryServer\InstanceName -Name 'MyAg' -Script </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會輸出 Transact-SQL 指令碼,這個指令碼會將位於指定路徑之伺服器執行個體所裝載的次要複本聯結至名為 'MyAg' 的可用性群組。這個伺服器執行個體必須裝載這個可用性群組中的次要複本。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>SQL Server Books Online: Joining a Secondary Replica to an Availability Group (SQL Server)</maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>New-SqlAvailabilityGroup</command:name><maml:description><maml:para>在即將裝載初始主要複本的伺服器執行個體上建立可用性群組。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>New</command:verb><command:noun>SqlAvailabilityGroup</command:noun><dev:version /></command:details><maml:description><maml:para>New-SqlAvailabilityGroup Cmdlet 會建立可用性群組。InputObject 或 Path 參數所指定的伺服器執行個體將會裝載初始主要複本。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>New-SqlAvailabilityGroup</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>要建立的可用性群組名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>即將裝載可用性群組之初始主要複本的 SQL Server 執行個體的路徑。如果指定的路徑不存在,則會擲回錯誤。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AutomatedBackupPreference</maml:name><maml:description><maml:para>可用性群組的自動備份喜好設定。有效的選項包括: </maml:para><maml:para>Primary:指定備份一定要在主要複本上進行。這通常是因為使用者需要在次要複本上執行備份時無法使用的功能,例如差異備份。 </maml:para><maml:para>SecondaryOnly:指定絕對不能在主要複本上執行備份。如果主要複本是唯一的線上複本,就不會進行備份。 </maml:para><maml:para>Secondary:指定除非主要複本是唯一的線上複本,否則備份會在次要複本上進行。然後,備份會在主要複本上進行。 </maml:para><maml:para>None:此選項會指定使用者在選擇要執行備份的複本時,不想要將主要/次要狀態納入考量。只考慮 BackupPriority 以及上線/已連接狀態等因素。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityGroupAutomatedBackupPreference</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>使用完整復原模式但不使用 AUTO_CLOSE 之本機讀寫使用者資料庫的清單。這些資料庫不能屬於另一個可用性群組,而且不得設定為資料庫鏡像。此參數不得為 Null 或空白。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailureConditionLevel</maml:name><maml:description><maml:para>決定可用性群組的自動容錯移轉行為。有效的選項包括: </maml:para><maml:para>OnServerDown:SQL Server 服務停止時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnServerUnresponsive:滿足任何狀況的較低值,而且 SQL Server 服務連接到叢集且超過 "HealthCheckTimeout" 臨界值,或者目前位於主要角色中的可用性複本處於失敗狀態時,便容錯移轉或重新啟動 (請參閱 HealthCheckTimeout 參數)。 </maml:para><maml:para>OnCriticalServerError:滿足任何狀況的較低值,而且發生內部嚴重伺服器錯誤 (記憶體不足的狀況、嚴重的寫入存取違規或傾印過多) 時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnModerateServerError:滿足任何狀況的較低值,而且發生一般伺服器錯誤 (持續的記憶體不足狀況) 時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnAnyQualifiedFailureConditions:滿足任何狀況的較低值,而且發生限定失敗狀況 (引擎工作者執行緒已耗盡、偵測到無法解決的死結) 時,便容錯移轉或重新啟動。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityGroupFailureConditionLevel</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>HealthCheckTimeout</maml:name><maml:description><maml:para>將沒有回應的伺服器宣告為狀況不良之前經過的時間長度。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AvailabilityReplica</maml:name><maml:description><maml:para>您想要包含在新可用性群組中之每個可用性複本的 AvailabilityReplica 物件。此參數可以是巢狀的,但是不得為空白或 Null。 </maml:para><maml:para>提示:若要建立 AvailabilityReplica 物件,請使用 New-SqlAvailabilityReplica Cmdlet 搭配 AsTemplate 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">AvailabilityReplica[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>New-SqlAvailabilityGroup</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>要建立的可用性群組名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>裝載主要複本之執行個體的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AutomatedBackupPreference</maml:name><maml:description><maml:para>可用性群組的自動備份喜好設定。有效的選項包括: </maml:para><maml:para>Primary:指定備份一定要在主要複本上進行。這通常是因為使用者需要在次要複本上執行備份時無法使用的功能,例如差異備份。 </maml:para><maml:para>SecondaryOnly:指定絕對不能在主要複本上執行備份。如果主要複本是唯一的線上複本,就不會進行備份。 </maml:para><maml:para>Secondary:指定除非主要複本是唯一的線上複本,否則備份會在次要複本上進行。然後,備份會在主要複本上進行。 </maml:para><maml:para>None:此選項會指定使用者在選擇要執行備份的複本時,不想要將主要/次要狀態納入考量。只考慮 BackupPriority 以及上線/已連接狀態等因素。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityGroupAutomatedBackupPreference</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>使用完整復原模式但不使用 AUTO_CLOSE 之本機讀寫使用者資料庫的清單。這些資料庫不能屬於另一個可用性群組,而且不得設定為資料庫鏡像。此參數不得為 Null 或空白。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailureConditionLevel</maml:name><maml:description><maml:para>決定可用性群組的自動容錯移轉行為。有效的選項包括: </maml:para><maml:para>OnServerDown:SQL Server 服務停止時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnServerUnresponsive:滿足任何狀況的較低值,而且 SQL Server 服務連接到叢集且超過 "HealthCheckTimeout" 臨界值,或者目前位於主要角色中的可用性複本處於失敗狀態時,便容錯移轉或重新啟動 (請參閱 HealthCheckTimeout 參數)。 </maml:para><maml:para>OnCriticalServerError:滿足任何狀況的較低值,而且發生內部嚴重伺服器錯誤 (記憶體不足的狀況、嚴重的寫入存取違規或傾印過多) 時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnModerateServerError:滿足任何狀況的較低值,而且發生一般伺服器錯誤 (持續的記憶體不足狀況) 時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnAnyQualifiedFailureConditions:滿足任何狀況的較低值,而且發生限定失敗狀況 (引擎工作者執行緒已耗盡、偵測到無法解決的死結) 時,便容錯移轉或重新啟動。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityGroupFailureConditionLevel</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>HealthCheckTimeout</maml:name><maml:description><maml:para>將沒有回應的伺服器宣告為狀況不良之前經過的時間長度。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AvailabilityReplica</maml:name><maml:description><maml:para>您想要包含在新可用性群組中之每個可用性複本的 AvailabilityReplica 物件。此參數可以是巢狀的,但是不得為空白或 Null。 </maml:para><maml:para>提示:若要建立 AvailabilityReplica 物件,請使用 New-SqlAvailabilityReplica Cmdlet 搭配 AsTemplate 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">AvailabilityReplica[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AutomatedBackupPreference</maml:name><maml:description><maml:para>可用性群組的自動備份喜好設定。有效的選項包括: </maml:para><maml:para>Primary:指定備份一定要在主要複本上進行。這通常是因為使用者需要在次要複本上執行備份時無法使用的功能,例如差異備份。 </maml:para><maml:para>SecondaryOnly:指定絕對不能在主要複本上執行備份。如果主要複本是唯一的線上複本,就不會進行備份。 </maml:para><maml:para>Secondary:指定除非主要複本是唯一的線上複本,否則備份會在次要複本上進行。然後,備份會在主要複本上進行。 </maml:para><maml:para>None:此選項會指定使用者在選擇要執行備份的複本時,不想要將主要/次要狀態納入考量。只考慮 BackupPriority 以及上線/已連接狀態等因素。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityGroupAutomatedBackupPreference</command:parameterValue><dev:type><maml:name>AvailabilityGroupAutomatedBackupPreference</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AvailabilityReplica</maml:name><maml:description><maml:para>您想要包含在新可用性群組中之每個可用性複本的 AvailabilityReplica 物件。此參數可以是巢狀的,但是不得為空白或 Null。 </maml:para><maml:para>提示:若要建立 AvailabilityReplica 物件,請使用 New-SqlAvailabilityReplica Cmdlet 搭配 AsTemplate 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">AvailabilityReplica[]</command:parameterValue><dev:type><maml:name>AvailabilityReplica[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>使用完整復原模式但不使用 AUTO_CLOSE 之本機讀寫使用者資料庫的清單。這些資料庫不能屬於另一個可用性群組,而且不得設定為資料庫鏡像。此參數不得為 Null 或空白。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailureConditionLevel</maml:name><maml:description><maml:para>決定可用性群組的自動容錯移轉行為。有效的選項包括: </maml:para><maml:para>OnServerDown:SQL Server 服務停止時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnServerUnresponsive:滿足任何狀況的較低值,而且 SQL Server 服務連接到叢集且超過 "HealthCheckTimeout" 臨界值,或者目前位於主要角色中的可用性複本處於失敗狀態時,便容錯移轉或重新啟動 (請參閱 HealthCheckTimeout 參數)。 </maml:para><maml:para>OnCriticalServerError:滿足任何狀況的較低值,而且發生內部嚴重伺服器錯誤 (記憶體不足的狀況、嚴重的寫入存取違規或傾印過多) 時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnModerateServerError:滿足任何狀況的較低值,而且發生一般伺服器錯誤 (持續的記憶體不足狀況) 時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnAnyQualifiedFailureConditions:滿足任何狀況的較低值,而且發生限定失敗狀況 (引擎工作者執行緒已耗盡、偵測到無法解決的死結) 時,便容錯移轉或重新啟動。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityGroupFailureConditionLevel</command:parameterValue><dev:type><maml:name>AvailabilityGroupFailureConditionLevel</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>HealthCheckTimeout</maml:name><maml:description><maml:para>將沒有回應的伺服器宣告為狀況不良之前經過的時間長度。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>裝載主要複本之執行個體的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue><dev:type><maml:name>Context</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>要建立的可用性群組名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>即將裝載可用性群組之初始主要複本的 SQL Server 執行個體的路徑。如果指定的路徑不存在,則會擲回錯誤。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.Server</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 指定包含主要複本的伺服器執行個體。 </maml:para><maml:para> </maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.AvailabilityGroup</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 包含可用性群組的新 Power Shell 物件。 </maml:para></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$primaryServer = Get-Item "SQLSERVER:\SQL\PrimaryServer\InstanceName" $secondaryServer = Get-Item "SQLSERVER:\SQL\SecondaryServer\InstanceName" $primaryReplica = New-SqlAvailabilityReplica ` -Name "PrimaryServer\InstanceName" ` -EndpointUrl "TCP://PrimaryServer.domain:5022" ` -FailoverMode "Automatic" ` -AvailabilityMode "SynchronousCommit" ` -AsTemplate ` -Version ($primaryServer.Version) # Create the initial secondary replica $secondaryReplica = New-SqlAvailabilityReplica ` -Name "SecondaryServer\InstanceName" ` -EndpointUrl "TCP://SecondaryServer.domain:5022" ` -FailoverMode "Automatic" ` -AvailabilityMode "SynchronousCommit" ` -AsTemplate ` -Version ($secondaryServer.Version) # Create the Availability Group. New-SqlAvailabilityGroup -InputObject $primaryServer -Name MyAG -AvailabilityReplica ($primaryReplica, $secondaryReplica) -Database @("MyDatabase1","MyDatabase2") </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會建立包含兩個可用性複本和兩個資料庫 ('MyDatabase1' 和 'MyDatabase2') 的新可用性群組 'MyAG'。首先,此範例會使用 New-SqlAvailabilityReplica Cmdlet 來建立兩個複本 ('$primaryReplica' 和 '$secondaryReplica') 的記憶體中表示法。這些複本會設定為使用同步認可的可用性模式搭配自動容錯移轉。其資料庫鏡像端點會使用通訊埠 5022。然後,此範例會使用 New-SqlAvailabilityGroup Cmdlet 來建立可用性群組。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>SQL Server Books Online: Creating an Availability Group (SQL Server)</maml:linkText><maml:uri /></maml:navigationLink><maml:navigationLink><maml:linkText>SQL Server Books Online: "HADR" Prerequisites and Restrictions</maml:linkText><maml:uri /></maml:navigationLink><maml:navigationLink><maml:linkText>SQL Server Books Online: Specifying the Endpoint URL for an Availability Replica (SQL Server)</maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>New-SqlAvailabilityGroupListener</command:name><maml:description><maml:para>建立新的可用性群組接聽程式,並將其附加至現有的可用性群組。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>New</command:verb><command:noun>SqlAvailabilityGroupListener</command:noun><dev:version /></command:details><maml:description><maml:para>New-SqlAvailabilityGroupListener Cmdlet 會建立新的可用性群組接聽程式,並將其附加至可用性群組。它可接受識別可用性群組和 IP 位址的參數。這個 Cmdlet 只能在裝載主要複本的伺服器執行個體上執行。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>New-SqlAvailabilityGroupListener</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>接聽程式的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組的路徑。新的接聽程式將會附加至此路徑所指定的可用性群組。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DhcpSubnet</maml:name><maml:description><maml:para>指定接聽程式應該在引數所指定的子網路上使用 DHCP。此引數應該是採用斜線標記法的 IPv4 位址和子網路遮罩,例如 192.168.0.1\255.255.255.0。 </maml:para><maml:para>StaticIp 和 DhcpSubnet 是互斥選項。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>接聽程式將用來接聽連接的通訊埠。預設通訊埠是 TCP 通訊埠 1433。如果您有安全性考量,我們建議您使用不同的通訊埠編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StaticIp</maml:name><maml:description><maml:para>指定應該使用引數所指定的靜態 IP 位址來設定接聽程式。這個引數應該是字串清單。其中每個字串都可以是採用斜線標記法的 IPv4 位址和子網路遮罩或 IPv6 位址。 </maml:para><maml:para>StaticIp 和 DhcpSubnet 是互斥選項。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>New-SqlAvailabilityGroupListener</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>接聽程式的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該附加接聽程式之目標可用性群組的 AvailabilityGroup 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DhcpSubnet</maml:name><maml:description><maml:para>指定接聽程式應該在引數所指定的子網路上使用 DHCP。此引數應該是採用斜線標記法的 IPv4 位址和子網路遮罩,例如 192.168.0.1\255.255.255.0。 </maml:para><maml:para>StaticIp 和 DhcpSubnet 是互斥選項。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>接聽程式將用來接聽連接的通訊埠。預設通訊埠是 TCP 通訊埠 1433。如果您有安全性考量,我們建議您使用不同的通訊埠編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StaticIp</maml:name><maml:description><maml:para>指定應該使用引數所指定的靜態 IP 位址來設定接聽程式。這個引數應該是字串清單。其中每個字串都可以是採用斜線標記法的 IPv4 位址和子網路遮罩或 IPv6 位址。 </maml:para><maml:para>StaticIp 和 DhcpSubnet 是互斥選項。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DhcpSubnet</maml:name><maml:description><maml:para>指定接聽程式應該在引數所指定的子網路上使用 DHCP。此引數應該是採用斜線標記法的 IPv4 位址和子網路遮罩,例如 192.168.0.1\255.255.255.0。 </maml:para><maml:para>StaticIp 和 DhcpSubnet 是互斥選項。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該附加接聽程式之目標可用性群組的 AvailabilityGroup 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue><dev:type><maml:name>Context</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>接聽程式的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組的路徑。新的接聽程式將會附加至此路徑所指定的可用性群組。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>接聽程式將用來接聽連接的通訊埠。預設通訊埠是 TCP 通訊埠 1433。如果您有安全性考量,我們建議您使用不同的通訊埠編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue>65535 </dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StaticIp</maml:name><maml:description><maml:para>指定應該使用引數所指定的靜態 IP 位址來設定接聽程式。這個引數應該是字串清單。其中每個字串都可以是採用斜線標記法的 IPv4 位址和子網路遮罩或 IPv6 位址。 </maml:para><maml:para>StaticIp 和 DhcpSubnet 是互斥選項。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.AvailabilityGroup</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>New-SqlAvailabilityGroupListener -Name MyListener -Path SQLSERVER:\SQL\PrimaryServer\InstanceName\AvailabilityGroups\MyAg </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會針對可用性群組 'MyAg' 建立名為 'MyListener' 的可用性群組接聽程式。這個接聽程式將使用 DHCP 來取得虛擬 IP 位址。此命令必須在裝載主要複本的伺服器執行個體上執行。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>New-SqlAvailabilityGroupListener -Name MyListener -Path SQLSERVER:\SQL\PrimaryServer\InstanceName\AvailabilityGroups\MyAg -Port 1434 </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會針對可用性群組 'MyAg' 建立名為 'MyListener' 的可用性群組接聽程式。這個接聽程式將使用 DHCP 來取得虛擬 IP 位址,並且接聽通訊埠 1434 的連接。此命令必須在裝載主要複本的伺服器執行個體上執行。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>New-SqlAvailabilityGroupListener -Name MyListener -DhcpSubnet '192.169.0.1/255.255.252.0' -Path SQLSERVER:\SQL\PrimaryServer\InstanceName\AvailabilityGroups\MyAg </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會針對可用性群組 'MyAg' 建立名為 'MyListener' 的可用性群組接聽程式。這個接聽程式將在指定的子網路上使用 DHCP 來取得虛擬 IP 位址。此命令必須在裝載主要複本的伺服器執行個體上執行。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 4 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>New-SqlAvailabilityGroupListener -Name MyListener -StaticIp '192.168.3.1/255.255.252.0' -Path SQLSERVER:\Sql\Computer\Instance\AvailabilityGroups\MyAg </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會針對可用性群組 'MyAg' 建立名為 'MyListener' 的可用性群組接聽程式。這個接聽程式將使用傳遞給 -StaticIp 參數的 IPv4 位址做為其虛擬 IP 位址。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 5 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>New-SqlAvailabilityGroupListener -Name MyListener -Path SQLSERVER:\Sql\Computer\Instance\AvailabilityGroups\MyAg -Script </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會輸出 Transact-SQL 指令碼,這個指令碼會針對可用性群組 'MyAg' 建立名為 'MyListener' 的可用性群組接聽程式。此命令實際上不會建立接聽程式。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>New-SqlAvailabilityReplica</command:name><maml:description><maml:para>建立可用性複本。這個 Cmdlet 必須在裝載主要可用性複本的伺服器執行個體上執行。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>New</command:verb><command:noun>SqlAvailabilityReplica</command:noun><dev:version /></command:details><maml:description><maml:para>New-SqlAvailabilityReplica Cmdlet 會建立可用性複本。這個 Cmdlet 必須在裝載主要複本的 SQL Server 執行個體上執行。 </maml:para><maml:para>AsTemplate、InputObject 和 Path 參數會互斥。 </maml:para><maml:para>若要在建立新的可用性群組之前建立 AvailabilityReplica 物件,請使用 AsTemplate 參數。 </maml:para><maml:para>將複本加入至現有的可用性群組時,請使用 InputObject 或 Path 參數來指定可用性群組的路徑。如果未指定任何參數,就會使用目前的路徑。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>New-SqlAvailabilityReplica</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>新可用性複本的名稱。請使用 computer\instance 格式來指定此名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組的路徑。新的複本將會屬於位於此路徑的可用性群組。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupPriority</maml:name><maml:description><maml:para>此選項是 0..100 範圍內的整數,而且表示執行備份之複本的所需優先權。系統會從在線上而且可用的複本集中選擇優先權最高的複本來執行備份。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInPrimaryRole</maml:name><maml:description><maml:para>主要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowReadWriteConnections:允取讀取/寫入連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInPrimaryRole</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInSecondaryRole</maml:name><maml:description><maml:para>次要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowNoConnections:不允許連接 </maml:para><maml:para>AllowReadIntentConnectionsOnly:只允許讀取意圖的連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInSecondaryRole</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadonlyRoutingConnectionUrl</maml:name><maml:description><maml:para>路由至複本進行唯讀連接時要使用的連接完整網域名稱 (FQDN) 和通訊埠。例如: </maml:para><maml:para>TCP://DBSERVER8.manufacturing.Adventure-Works.com:7024 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadOnlyRoutingList</maml:name><maml:description><maml:para>複本伺服器名稱的排序清單,這些名稱表示透過此可用性複本重新導向唯讀連接時供連接導向器使用的探查順序。這適用於可用性複本為可用性群組之目前主要複本的情況。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SessionTimeout</maml:name><maml:description><maml:para>將連接視為失敗之前,在主要複本與這個複本之間等候回應的秒數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AvailabilityMode</maml:name><maml:description><maml:para>指出複本為同步認可或非同步認可模式。它可以是 Null。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaAvailabilityMode</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EndpointUrl</maml:name><maml:description><maml:para>資料庫鏡像端點的 URL。此 URL 是採用 TCP://system-address:port 格式的 TCP 位址。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailoverMode</maml:name><maml:description><maml:para>可以是 Automatic 或 Manual。它可以是 Null。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaFailoverMode</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>New-SqlAvailabilityReplica</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>新可用性複本的名稱。請使用 computer\instance 格式來指定此名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AsTemplate</maml:name><maml:description><maml:para>您想要在記憶體中建立暫存 AvailabilityReplica 物件之新可用性複本的路徑。請使用 AsTemplate 來建立您計畫包含在新可用性群組中的每個新可用性複本。然後,透過執行 New-SqlAvailabilityGroup Cmdlet,建立可用性群組,並且將 AvailabilityReplica 物件指定為 AvailabilityReplica 參數的值。 </maml:para><maml:para>當您指定了 AsTemplate 時,系統會忽略 InputObject 和 Path 參數。 </maml:para><maml:para>指定 AsTemplate 時,您必須將 SQL Server 版本傳遞給 Version 參數,否則目前的工作階段就必須具有執行個體的使用中連接。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupPriority</maml:name><maml:description><maml:para>此選項是 0..100 範圍內的整數,而且表示執行備份之複本的所需優先權。系統會從在線上而且可用的複本集中選擇優先權最高的複本來執行備份。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInPrimaryRole</maml:name><maml:description><maml:para>主要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowReadWriteConnections:允取讀取/寫入連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInPrimaryRole</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInSecondaryRole</maml:name><maml:description><maml:para>次要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowNoConnections:不允許連接 </maml:para><maml:para>AllowReadIntentConnectionsOnly:只允許讀取意圖的連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInSecondaryRole</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadonlyRoutingConnectionUrl</maml:name><maml:description><maml:para>路由至複本進行唯讀連接時要使用的連接完整網域名稱 (FQDN) 和通訊埠。例如: </maml:para><maml:para>TCP://DBSERVER8.manufacturing.Adventure-Works.com:7024 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadOnlyRoutingList</maml:name><maml:description><maml:para>複本伺服器名稱的排序清單,這些名稱表示透過此可用性複本重新導向唯讀連接時供連接導向器使用的探查順序。這適用於可用性複本為可用性群組之目前主要複本的情況。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SessionTimeout</maml:name><maml:description><maml:para>將連接視為失敗之前,在主要複本與這個複本之間等候回應的秒數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Version</maml:name><maml:description><maml:para>指定 SQL Server 版本。只有在指定 AsTemplate 時,這個參數才有用。系統會在具有這個版本的伺服器上,以設計模式建立範本物件。 </maml:para><maml:para>您可以視需要將 Version 指定為整數或字串。例如: -Version %PRODUCT_MAJOR_VER%, 或 -Version "%PRODUCT_MAJOR_VER%.0.0" </maml:para></maml:description><command:parameterValue required="true" variableLength="false">ServerVersion</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AvailabilityMode</maml:name><maml:description><maml:para>指出複本為同步認可或非同步認可模式。它可以是 Null。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaAvailabilityMode</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EndpointUrl</maml:name><maml:description><maml:para>資料庫鏡像端點的 URL。此 URL 是採用 TCP://system-address:port 格式的 TCP 位址。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailoverMode</maml:name><maml:description><maml:para>可以是 Automatic 或 Manual。它可以是 Null。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaFailoverMode</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>New-SqlAvailabilityReplica</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>新可用性複本的名稱。請使用 computer\instance 格式來指定此名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>新複本所屬之可用性群組的 AvailabilityGroup 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupPriority</maml:name><maml:description><maml:para>此選項是 0..100 範圍內的整數,而且表示執行備份之複本的所需優先權。系統會從在線上而且可用的複本集中選擇優先權最高的複本來執行備份。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInPrimaryRole</maml:name><maml:description><maml:para>主要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowReadWriteConnections:允取讀取/寫入連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInPrimaryRole</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInSecondaryRole</maml:name><maml:description><maml:para>次要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowNoConnections:不允許連接 </maml:para><maml:para>AllowReadIntentConnectionsOnly:只允許讀取意圖的連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInSecondaryRole</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadonlyRoutingConnectionUrl</maml:name><maml:description><maml:para>路由至複本進行唯讀連接時要使用的連接完整網域名稱 (FQDN) 和通訊埠。例如: </maml:para><maml:para>TCP://DBSERVER8.manufacturing.Adventure-Works.com:7024 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadOnlyRoutingList</maml:name><maml:description><maml:para>複本伺服器名稱的排序清單,這些名稱表示透過此可用性複本重新導向唯讀連接時供連接導向器使用的探查順序。這適用於可用性複本為可用性群組之目前主要複本的情況。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SessionTimeout</maml:name><maml:description><maml:para>將連接視為失敗之前,在主要複本與這個複本之間等候回應的秒數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AvailabilityMode</maml:name><maml:description><maml:para>指出複本為同步認可或非同步認可模式。它可以是 Null。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaAvailabilityMode</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EndpointUrl</maml:name><maml:description><maml:para>資料庫鏡像端點的 URL。此 URL 是採用 TCP://system-address:port 格式的 TCP 位址。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailoverMode</maml:name><maml:description><maml:para>可以是 Automatic 或 Manual。它可以是 Null。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaFailoverMode</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AsTemplate</maml:name><maml:description><maml:para>您想要在記憶體中建立暫存 AvailabilityReplica 物件之新可用性複本的路徑。請使用 AsTemplate 來建立您計畫包含在新可用性群組中的每個新可用性複本。然後,透過執行 New-SqlAvailabilityGroup Cmdlet,建立可用性群組,並且將 AvailabilityReplica 物件指定為 AvailabilityReplica 參數的值。 </maml:para><maml:para>當您指定了 AsTemplate 時,系統會忽略 InputObject 和 Path 參數。 </maml:para><maml:para>指定 AsTemplate 時,您必須將 SQL Server 版本傳遞給 Version 參數,否則目前的工作階段就必須具有執行個體的使用中連接。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>0</dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AvailabilityMode</maml:name><maml:description><maml:para>指出複本為同步認可或非同步認可模式。它可以是 Null。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaAvailabilityMode</command:parameterValue><dev:type><maml:name>AvailabilityReplicaAvailabilityMode</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupPriority</maml:name><maml:description><maml:para>此選項是 0..100 範圍內的整數,而且表示執行備份之複本的所需優先權。系統會從在線上而且可用的複本集中選擇優先權最高的複本來執行備份。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInPrimaryRole</maml:name><maml:description><maml:para>主要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowReadWriteConnections:允取讀取/寫入連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInPrimaryRole</command:parameterValue><dev:type><maml:name>AvailabilityReplicaConnectionModeInPrimaryRole</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInSecondaryRole</maml:name><maml:description><maml:para>次要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowNoConnections:不允許連接 </maml:para><maml:para>AllowReadIntentConnectionsOnly:只允許讀取意圖的連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInSecondaryRole</command:parameterValue><dev:type><maml:name>AvailabilityReplicaConnectionModeInSecondaryRole</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EndpointUrl</maml:name><maml:description><maml:para>資料庫鏡像端點的 URL。此 URL 是採用 TCP://system-address:port 格式的 TCP 位址。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailoverMode</maml:name><maml:description><maml:para>可以是 Automatic 或 Manual。它可以是 Null。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaFailoverMode</command:parameterValue><dev:type><maml:name>AvailabilityReplicaFailoverMode</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>新複本所屬之可用性群組的 AvailabilityGroup 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue><dev:type><maml:name>Context</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>新可用性複本的名稱。請使用 computer\instance 格式來指定此名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組的路徑。新的複本將會屬於位於此路徑的可用性群組。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadonlyRoutingConnectionUrl</maml:name><maml:description><maml:para>路由至複本進行唯讀連接時要使用的連接完整網域名稱 (FQDN) 和通訊埠。例如: </maml:para><maml:para>TCP://DBSERVER8.manufacturing.Adventure-Works.com:7024 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadOnlyRoutingList</maml:name><maml:description><maml:para>複本伺服器名稱的排序清單,這些名稱表示透過此可用性複本重新導向唯讀連接時供連接導向器使用的探查順序。這適用於可用性複本為可用性群組之目前主要複本的情況。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SessionTimeout</maml:name><maml:description><maml:para>將連接視為失敗之前,在主要複本與這個複本之間等候回應的秒數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Version</maml:name><maml:description><maml:para>指定 SQL Server 版本。只有在指定 AsTemplate 時,這個參數才有用。系統會在具有這個版本的伺服器上,以設計模式建立範本物件。 </maml:para><maml:para>您可以視需要將 Version 指定為整數或字串。例如: -Version %PRODUCT_MAJOR_VER%, 或 -Version "%PRODUCT_MAJOR_VER%.0.0" </maml:para></maml:description><command:parameterValue required="true" variableLength="false">ServerVersion</command:parameterValue><dev:type><maml:name>ServerVersion</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.AvailabilityGroup</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 指定複本的可用性群組。 </maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.AvailabilityReplica</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 包含新建立之可用性複本的 Power Shell 物件。 </maml:para></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$serverObject = (Get-Item SQLSERVER:\Sql\PrimaryServer\InstanceName) $serverVersion = $serverObject.Version $endpointURL = "TCP://PrimaryServerName.domain.com:5022" $failoverMode = "Automatic" $availabilityMode = "SynchronousCommit" New-SqlAvailabilityReplica -Name PrimaryServer\Instance -EndpointUrl $endpointURL -FailoverMode $failoverMode -AvailabilityMode $availabilityMode -AsTemplate -Version $serverVersion </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會建立可用性複本的記憶體中表示法。伺服器不會認可任何變更。此複本應該傳遞給 New-SqlAvailabilityGroup Cmdlet 的 AvailabilityReplica 參數。此複本將會使用位於指定 URL 的資料庫鏡像端點,與可用性群組中的其他複本進行通訊。此複本支援自動容錯移轉和同步認可的可用性模式。-AsTemplate 和 -Version 參數是建構記憶體中表示法的必要參數。-Version 參數會指定將裝載此複本之伺服器執行個體的版本。版本號碼必須是 11。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$serverObject = (Get-Item SQLSERVER:\Sql\PrimaryServer\InstanceName) $serverVersion = $serverObject.Version $endpointURL = "TCP://PrimaryServerName.domain.com:5022" $failoverMode = "Manual" $availabilityMode = "AsynchronousCommit" New-SqlAvailabilityReplica -Name SecondaryServer\Instance -EndpointUrl $endpointURL -FailoverMode $failoverMode -AvailabilityMode $availabilityMode -AsTemplate -Version $serverVersion </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會建立可用性複本的記憶體中表示法。伺服器不會認可任何變更。此複本應該傳遞給 New-SqlAvailabilityGroup Cmdlet 的 AvailabilityReplica 參數。此複本將會使用位於指定 URL 的端點,與可用性群組中的其他複本進行通訊。此複本支援手動容錯移轉和非同步認可的可用性模式。-AsTemplate 和 -Version 參數是建構記憶體中表示法的必要參數。-Version 參數會指定將裝載此複本之伺服器執行個體的版本。版本號碼必須是 11。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$agPath = "SQLSERVER:\Sql\PrimaryServer\InstanceName\AvailabilityGroups\MyAg" $endpointURL = "TCP://PrimaryServerName.domain.com:5022" $failoverMode = "Manual" $availabilityMode = "AsynchronousCommit" $secondaryReadMode = "AllowAllConnections" New-SqlAvailabilityReplica -Name SecondaryServer\Instance -EndpointUrl $endpointURL -FailoverMode $failoverMode -AvailabilityMode $availabilityMode -ConnectionModeInSecondaryRole $secondaryReadMode -Path $agPath </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會將可用性複本加入至名為 'MyAg' 的現有可用性群組。此複本支援手動容錯移轉和非同步認可的可用性模式。在次要角色中,此複本將支援讀取連接,可讓您將唯讀處理卸載至此複本。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>SQL Server Books Online: Specifying the Endpoint URL for an Availability Replica (SQL Server)</maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>New-SqlBackupEncryptionOption</command:name><maml:description><maml:para>定義 Backup-SqlDatabase Cmdlet 或 Set-SqlSmartAdmin Cmdlet 的加密選項。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>New</command:verb><command:noun>SqlBackupEncryptionOption</command:noun><dev:version /></command:details><maml:description><maml:para></maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>New-SqlBackupEncryptionOption</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Algorithm</maml:name><maml:description><maml:para>加密演算法。可能的值為:AES128、AES192、AES256 和 TripleDes。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptionAlgorithm</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptorName</maml:name><maml:description><maml:para>伺服器憑證或伺服器非對稱金鑰的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptorType</maml:name><maml:description><maml:para>加密程式類型。可能的值為 ServerCertificate 和 ServerAsymmetricKey。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptorType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoEncryption</maml:name><maml:description><maml:para>指定停用加密。這個參數不能搭配任何其他參數使用。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Algorithm</maml:name><maml:description><maml:para>加密演算法。可能的值為:AES128、AES192、AES256 和 TripleDes。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptionAlgorithm</command:parameterValue><dev:type><maml:name>BackupEncryptionAlgorithm</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptorName</maml:name><maml:description><maml:para>伺服器憑證或伺服器非對稱金鑰的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptorType</maml:name><maml:description><maml:para>加密程式類型。可能的值為 ServerCertificate 和 ServerAsymmetricKey。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptorType</command:parameterValue><dev:type><maml:name>BackupEncryptorType</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoEncryption</maml:name><maml:description><maml:para>指定停用加密。這個參數不能搭配任何其他參數使用。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.BackupEncryptionOptions</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para>用來當做 Backup-SqlDatabase 和 Set-SqlSmartAdmin 之 –EncryptionOption 參數的輸入。</maml:para></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$encryptionOption = New-SqlBackupEncryptionOption -Algorithm Aes256 -EncryptorType ServerCertificate -EncryptorName "BackupCert" </dev:code><dev:code>C:\PS>Backup-SqlDatabase -ServerInstance . -Database "db1" -BackupFile "db1.bak" -CompressionOption On -EncryptionOption $encryptionOption </dev:code><dev:remarks><maml:para>此範例會建立加密選項,然後將它當做 Backup-SqlDatabase 的參數值使用,以建立加密備份。</maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>Online Version:</maml:linkText><maml:uri></maml:uri></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>New-SqlCredential</command:name><maml:description><maml:para>建立新的 SQL Server Credential 物件。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>New</command:verb><command:noun>SqlCredential</command:noun><dev:version /></command:details><maml:description><maml:para>New-SqlCredential Cmdlet 會建立新的 SQL Server Credential 物件。SQL Server Credential 物件可用來儲存驗證資訊。您必須使用 SQL Server 認證才能將資料備份至 Windows Azure 儲存體服務或從中還原,SQL Server 認證可用來儲存 Windows Azure 儲存體服務帳戶名稱和存取金鑰資訊。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>New-SqlCredential</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>認證的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值會使用目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ProviderName</maml:name><maml:description><maml:para>密碼編譯提供者名稱。指定 Enterprise Key Management (EKM) 提供者的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Secret</maml:name><maml:description><maml:para>使用者或帳戶的密碼。如果是 Windows Azure 儲存體服務驗證,這個參數就是儲存體帳戶存取金鑰值。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">SecureString</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Identity</maml:name><maml:description><maml:para>使用者或帳戶的名稱。如果是 Windows Azure 儲存體服務驗證,這個參數就是 Windows Azure 儲存體帳戶的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>New-SqlCredential</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>認證的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>Server 物件,您必須在這個位置建立認證。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ProviderName</maml:name><maml:description><maml:para>密碼編譯提供者名稱。指定 Enterprise Key Management (EKM) 提供者的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Secret</maml:name><maml:description><maml:para>使用者或帳戶的密碼。如果是 Windows Azure 儲存體服務驗證,這個參數就是儲存體帳戶存取金鑰值。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">SecureString</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Identity</maml:name><maml:description><maml:para>使用者或帳戶的名稱。如果是 Windows Azure 儲存體服務驗證,這個參數就是 Windows Azure 儲存體帳戶的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Identity</maml:name><maml:description><maml:para>使用者或帳戶的名稱。如果是 Windows Azure 儲存體服務驗證,這個參數就是 Windows Azure 儲存體帳戶的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>Server 物件,您必須在這個位置建立認證。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue><dev:type><maml:name>Context</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>認證的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值會使用目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ProviderName</maml:name><maml:description><maml:para>密碼編譯提供者名稱。指定 Enterprise Key Management (EKM) 提供者的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Secret</maml:name><maml:description><maml:para>使用者或帳戶的密碼。如果是 Windows Azure 儲存體服務驗證,這個參數就是儲存體帳戶存取金鑰值。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">SecureString</command:parameterValue><dev:type><maml:name>SecureString</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS> cd SQLServer:\SQL\Computer\Instance $storageAccount = “myWindowsAzureStorageAccount” $storageKey = “<storage account access key value>” New-SqlCredential – name “mysqlcredential” –Identity $storageAccount –secret $storageKey </dev:code><dev:remarks><maml:para>此命令會在目前的 SQL Server 執行個體中建立 SQL Credential "mysqlcredential"。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>#cd to computer level cd sqlserver:\sql\computer $storageAccount = “myWindowsAzureStorageAccount” $storageKey = “<storage account access key value>” $secureString = convertto-securestring $storageKey -asplaintext -force # get the list of instances $instances = Get-childitem #pipe the instances to new-sqlcredentail cmdlet to create SQL credential $instances | new-sqlcredential -Name “mysqlcredential” -Identity storageAccount -Secret $secureString </dev:code><dev:remarks><maml:para>此命令會針對所有 SQL Server 執行個體建立 SQL Credential "mysqlcredential"。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>New-SqlHADREndpoint</command:name><maml:description><maml:para>在 SQL Server 執行個體上建立資料庫鏡像端點。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>New</command:verb><command:noun>SqlHADREndpoint</command:noun><dev:version /></command:details><maml:description><maml:para>New-SqlHadrndpoint Cmdlet 會在指定的 SQL Server 執行個體上建立資料庫鏡像端點。裝載任何可用性群組之可用性複本的每個伺服器執行個體都需要這個端點。每個伺服器執行個體只能有一個資料庫鏡像端點。如果伺服器執行個體已經擁有資料庫鏡像端點,請使用現有的端點。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>New-SqlHADREndpoint</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>要建立的端點名稱。這是強制參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>要建立端點之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AuthenticationOrder</maml:name><maml:description><maml:para>端點所使用的驗證順序和類型。選項包括 Certificate、CertificateKerberos、CertificateNegotiate、CertificateNtlm、Kerberos、KerberosCertificate、Negotiate、NegotiateCertificate、Ntlm 和 NtlmCertificate。如果指定的選項需要憑證,您也必須設定 -Certificate 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointAuthenticationOrder</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Certificate</maml:name><maml:description><maml:para>端點應該用來驗證連接的憑證名稱。遠端點必須有一個特定憑證,該憑證含有符合指定憑證之私密金鑰的公開金鑰。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Encryption</maml:name><maml:description><maml:para>端點的加密選項。選項包括 Disabled、Supported 或 Required。Required 是預設值。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointEncryption</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionAlgorithm</maml:name><maml:description><maml:para>端點所使用的加密格式。選項包括 Aes、AesRC4、None、RC4 和 RC4Aes。根據預設,端點將使用 Aes 加密。 </maml:para><maml:para>注意:只有 RC4 演算法支援回溯相容性。只有在資料庫相容性層級為 90 或 100 時,才能使用 RC4 或 RC4_128 加密新資料 (不建議使用)。請改用較新的演算法,例如其中一個 AES 演算法。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointEncryptionAlgorithm</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>IpAddress</maml:name><maml:description><maml:para>端點將接聽的 IP 位址。預設值為 ALL,表示接聽程式會接受任何有效 IP 位址的連接。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">IPAddress</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Owner</maml:name><maml:description><maml:para>端點擁有者的登入。根據預設,這是目前登入。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>端點將用來接聽連接的 TCP 通訊埠。預設通訊埠是 5022。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>New-SqlHADREndpoint</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>要建立的端點名稱。這是強制參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該建立端點之 SQL Server 執行個體的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AuthenticationOrder</maml:name><maml:description><maml:para>端點所使用的驗證順序和類型。選項包括 Certificate、CertificateKerberos、CertificateNegotiate、CertificateNtlm、Kerberos、KerberosCertificate、Negotiate、NegotiateCertificate、Ntlm 和 NtlmCertificate。如果指定的選項需要憑證,您也必須設定 -Certificate 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointAuthenticationOrder</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Certificate</maml:name><maml:description><maml:para>端點應該用來驗證連接的憑證名稱。遠端點必須有一個特定憑證,該憑證含有符合指定憑證之私密金鑰的公開金鑰。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Encryption</maml:name><maml:description><maml:para>端點的加密選項。選項包括 Disabled、Supported 或 Required。Required 是預設值。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointEncryption</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionAlgorithm</maml:name><maml:description><maml:para>端點所使用的加密格式。選項包括 Aes、AesRC4、None、RC4 和 RC4Aes。根據預設,端點將使用 Aes 加密。 </maml:para><maml:para>注意:只有 RC4 演算法支援回溯相容性。只有在資料庫相容性層級為 90 或 100 時,才能使用 RC4 或 RC4_128 加密新資料 (不建議使用)。請改用較新的演算法,例如其中一個 AES 演算法。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointEncryptionAlgorithm</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>IpAddress</maml:name><maml:description><maml:para>端點將接聽的 IP 位址。預設值為 ALL,表示接聽程式會接受任何有效 IP 位址的連接。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">IPAddress</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Owner</maml:name><maml:description><maml:para>端點擁有者的登入。根據預設,這是目前登入。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>端點將用來接聽連接的 TCP 通訊埠。預設通訊埠是 5022。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AuthenticationOrder</maml:name><maml:description><maml:para>端點所使用的驗證順序和類型。選項包括 Certificate、CertificateKerberos、CertificateNegotiate、CertificateNtlm、Kerberos、KerberosCertificate、Negotiate、NegotiateCertificate、Ntlm 和 NtlmCertificate。如果指定的選項需要憑證,您也必須設定 -Certificate 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointAuthenticationOrder</command:parameterValue><dev:type><maml:name>EndpointAuthenticationOrder</maml:name><maml:uri /></dev:type><dev:defaultValue>SMO.EndpointAuthenticationOrder.Negotiate</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Certificate</maml:name><maml:description><maml:para>端點應該用來驗證連接的憑證名稱。遠端點必須有一個特定憑證,該憑證含有符合指定憑證之私密金鑰的公開金鑰。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Encryption</maml:name><maml:description><maml:para>端點的加密選項。選項包括 Disabled、Supported 或 Required。Required 是預設值。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointEncryption</command:parameterValue><dev:type><maml:name>EndpointEncryption</maml:name><maml:uri /></dev:type><dev:defaultValue>SMO.EndpointAuthentication.Required</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionAlgorithm</maml:name><maml:description><maml:para>端點所使用的加密格式。選項包括 Aes、AesRC4、None、RC4 和 RC4Aes。根據預設,端點將使用 Aes 加密。 </maml:para><maml:para>注意:只有 RC4 演算法支援回溯相容性。只有在資料庫相容性層級為 90 或 100 時,才能使用 RC4 或 RC4_128 加密新資料 (不建議使用)。請改用較新的演算法,例如其中一個 AES 演算法。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointEncryptionAlgorithm</command:parameterValue><dev:type><maml:name>EndpointEncryptionAlgorithm</maml:name><maml:uri /></dev:type><dev:defaultValue>RC4</dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="3" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該建立端點之 SQL Server 執行個體的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Context</command:parameterValue><dev:type><maml:name>Context</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>IpAddress</maml:name><maml:description><maml:para>端點將接聽的 IP 位址。預設值為 ALL,表示接聽程式會接受任何有效 IP 位址的連接。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">IPAddress</command:parameterValue><dev:type><maml:name>IPAddress</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Name</maml:name><maml:description><maml:para>要建立的端點名稱。這是強制參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Owner</maml:name><maml:description><maml:para>端點擁有者的登入。根據預設,這是目前登入。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>要建立端點之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>端點將用來接聽連接的 TCP 通訊埠。預設通訊埠是 5022。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue>5022</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>SMO.Server</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 此參數會指定要建立端點的伺服器執行個體。 </maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name>SMO.Endpoint</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>New-SqlHADREndpoint -Path SQLSERVER:\Sql\Computer\Instance -Name MyEndpoint </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在位於指定路徑的伺服器執行個體上建立名為 'MyEndpoint' 的資料庫鏡像端點。此端點會使用預設通訊埠 5022。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>New-SqlHADREndpoint -Path SQLSERVER:\Sql\Computer\Instance -Name EndpointName -Port 4022 -EncryptionAlgorithm 'Aes' -Encryption 'Required' </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在位於指定路徑的伺服器執行個體上建立名為 'MyEndpoint' 的資料庫鏡像端點。此端點會接聽通訊埠 4022。此端點會使用 AES 演算法進行加密,並且要求連接使用加密。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>New-SqlHADREndpoint -Path SQLSERVER:\Sql\Computer\Instance -Name EndpointName -AuthenticationOrder 'Certificate' -Certificate 'MyCertificate' </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會在位於指定路徑的伺服器執行個體上建立名為 'MyEndpoint' 的資料庫鏡像端點。此端點會使用名為 'MyCertificate' 的憑證來驗證連接。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 4 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>New-SqlHADREndpoint -Path SQLSERVER:\Sql\Computer\Instance -Name MyEndpoint -Script </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會輸出 Transact-SQL 指令碼,這個指令碼會在位於指定路徑的伺服器執行個體上建立名為 'MyEndpoint' 的資料庫鏡像端點。此命令實際上不會建立端點。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Remove-SqlAvailabilityDatabase</command:name><maml:description><maml:para>從可用性群組中移除 InputObject 或 Path 參數所指定的可用性資料庫。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Remove</command:verb><command:noun>SqlAvailabilityDatabase</command:noun><dev:version /></command:details><maml:description><maml:para>Remove-SqlAvailabilityDatabase Cmdlet 會從可用性群組中移除 InputObject 或 Path 參數所指定的可用性資料庫。如果在裝載主要複本的伺服器執行個體上執行,這個 Cmdlet 就會從可用性群組中移除主要資料庫及所有對應的次要資料庫。如果在裝載次要複本的伺服器執行個體上執行,這個 Cmdlet 只會從可用性群組中移除本機次要資料庫。這個次要資料庫將不再聯結至可用性群組,但是資料庫的其他複本會繼續保持聯結狀態。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Remove-SqlAvailabilityDatabase</maml:name><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性資料庫的路徑。這是強制參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Remove-SqlAvailabilityDatabase</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>要移除之可用性資料庫的 AvailabilityDatabase 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>要移除之可用性資料庫的 AvailabilityDatabase 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue><dev:type><maml:name>Target</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性資料庫的路徑。這是強制參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.AvailabilityDatabase</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 指定要移除的可用性資料庫。 </maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Remove-SqlAvailabilityDatabase -Path SQLSERVER:\Sql\PrimaryComputer\InstanceName\AvailabilityGroups\MyAg\AvailabilityDatabases\MyDatabase </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會從名為 'MyAg' 的可用性群組中移除可用性資料庫 'MyDatabase'。因為此命令是在裝載主要複本的伺服器執行個體上執行,所以系統會從可用性群組中移除主要資料庫及其所有對應的次要資料庫。系統將不再針對任何次要複本的這個資料庫進行資料同步處理。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Get-ChildItem SQLSERVER:\Sql\PrimaryComputer\InstanceName\AvailabilityGroups\MyAg\AvailabilityDatabases | Remove-SqlAvailabilityDatabase </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會從名為 'MyAg' 的可用性群組中移除所有可用性資料庫。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Remove-SqlAvailabilityDatabase -Path SQLSERVER:\Sql\SecondaryComputer\InstanceName\AvailabilityGroups\MyAg\AvailabilityDatabases\MyDatabase </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會從伺服器執行個體 'SecondaryComputer\Instance' 所裝載的次要複本中移除次要資料庫 'MyDatabase'。已移除之次要資料庫的資料同步處理會停止。此命令不會影響主要資料庫或任何其他次要資料庫。 </maml:para><maml:para>注意:若要在這個次要資料庫上重新啟動資料同步處理,請在相同的伺服器執行個體上使用 Add-SqlAvailabilityDatabase Cmdlet,將次要資料庫聯結至可用性群組。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 4 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Remove-SqlAvailabilityDatabase -Path SQLSERVER:\Sql\PrimaryComputer\InstanceName\AvailabilityGroups\MyAg\AvailabilityDatabases\MyDatabase -Script </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會輸出 Transact-SQL 命令,這個命令會從可用性群組 'MyAg' 中移除可用性資料庫 'MyDatabase'。此命令實際上不會移除可用性資料庫。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Remove-SqlAvailabilityGroup</command:name><maml:description><maml:para>移除 InputObject 或 Path 參數所指定的可用性群組。 </maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Remove</command:verb><command:noun>SqlAvailabilityGroup</command:noun><dev:version /></command:details><maml:description><maml:para>Remove-SqlAvailabilityGroup Cmdlet 會移除 InputObject 或 Path 參數所指定的可用性群組。這個 Cmdlet 可以移除已部分建立的可用性群組。在擁有可用性群組之正確安全性認證的 WSFC 節點上,此 Cmdlet 可以在已啟用 AlwaysOn 可用性群組的任何 SQL Server 執行個體上執行。如果執行此 Cmdlet 的執行個體未啟用 AlwaysOn 可用性群組,或者 Path 參數所指定的可用性群組不存在,則會擲回錯誤。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Remove-SqlAvailabilityGroup</maml:name><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組的路徑。這是強制參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Remove-SqlAvailabilityGroup</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>要移除之可用性群組的 AvailabilityGroup 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>要移除之可用性群組的 AvailabilityGroup 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue><dev:type><maml:name>Target</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組的路徑。這是強制參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.AvailabilityGroup</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Remove-SqlAvailabilityGroup -Path SQLSERVER:\Sql\Computer\Instance\AvailabilityGroups\MyAg </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會移除名為 'MyAg' 的可用性群組。此命令可以在裝載可用性群組之可用性複本的任何伺服器執行個體上執行。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Get-ChildItem SQLSERVER:\Sql\Computer\Instance\AvailabilityGroups | Remove-SqlAvailabilityGroup </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會移除包含伺服器執行個體 'Computer\Instance' 所裝載之可用性複本的所有可用性群組。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Remove-SqlAvailabilityGroup -Path SQLSERVER:\Sql\Computer\Instance\AvailabilityGroups\MyAg -Script </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會輸出 Transact-SQL 指令碼,這個指令碼會移除名為 'MyAg' 的可用性群組。此命令實際上不會移除可用性群組。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>SQL Server Books Online: DROP AVAILABILITY GROUP (Transact-SQL)</maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Remove-SqlAvailabilityReplica</command:name><maml:description><maml:para>移除 InputObject 或 Path 參數所指定的次要可用性複本。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Remove</command:verb><command:noun>SqlAvailabilityReplica</command:noun><dev:version /></command:details><maml:description><maml:para>Remove-SqlAvailabilityGroup Cmdlet 會移除 InputObject 或 Path 參數所指定的次要複本。這個 Cmdlet 只能在裝載主要複本的伺服器執行個體上執行。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Remove-SqlAvailabilityReplica</maml:name><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性複本的路徑。這是強制參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Remove-SqlAvailabilityReplica</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該移除之複本的 AvailabilityReplica 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該移除之複本的 AvailabilityReplica 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue><dev:type><maml:name>Target</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性複本的路徑。這是強制參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.AvailabilityReplica</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 要移除的可用性複本。 </maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Remove-SqlAvailabilityReplica -Path SQLSERVER:\SQL\PrimaryServer\InstanceName\AvailabilityGroups\MyAg\AvailabilityReplicas\MyReplica </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會從名為 'MyAg' 的可用性群組中移除名為 'MyReplica' 的可用性複本。此命令必須在裝載可用性群組之主要複本的伺服器執行個體上執行。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Remove-SqlAvailabilityReplica -Path SQLSERVER:\SQL\PrimaryServer\InstanceName\AvailabilityGroups\MyAg\AvailabilityReplicas\MyReplica -Script </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會輸出 Transact-SQL 指令碼,這個指令碼會從名為 'MyAg' 的可用性群組中移除名為 'MyReplica' 的可用性複本。此命令實際上不會移除複本。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>SQL Server Books Online: Deleting an Availability Group (SQL Server)</maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Remove-SqlCredential</command:name><maml:description><maml:para>刪除 SQL Credential 物件。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Remove</command:verb><command:noun>SqlCredential</command:noun><dev:version /></command:details><maml:description><maml:para>Remove-SqlCredential Cmdlet 會刪除 SQL Server 認證物件。這個 Cmdlet 支援下列兩種作業模式: 1.藉由使用 –path 參數指定內含認證名稱的認證路徑或位置。 2.藉由使用 –InputObject 參數將 Smo.Credential 物件傳遞給物件。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Remove-SqlCredential</maml:name><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行此作業之 Credential 的路徑。例如:SQLSERVER:\SQL\Computer\Instance\Credentials\Credential </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Remove-SqlCredential</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>輸入認證物件。您可以使用 Get-SqlCredential Cmdlet 取得這個物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>輸入認證物件。您可以使用 Get-SqlCredential Cmdlet 取得這個物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue><dev:type><maml:name>Target</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行此作業之 Credential 的路徑。例如:SQLSERVER:\SQL\Computer\Instance\Credentials\Credential </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>Remove-SqlCredential -Path SQLSERVER:\SQL\Computer\Instance\Credentials\MySqlCredential </dev:code><dev:remarks><maml:para>此命令會使用 –path 參數中指定的路徑來刪除 SQL Credential 'MySqlCredential'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>The command retrieves the credential object from the Get-Credential cmdlet and then pipes it to the Remove-Sql Credential cmdlet to delete the SQL Credential ‘MySqlCredential’. PS C:\>$cred = Get-SqlCredential -Name MySqlCredential $cred | Remove-SqlCredential </dev:code><dev:remarks></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Remove-SqlFirewallRule</command:name><maml:description><maml:para>停用可允許特定 SQL Server 執行個體連線的 Windows 防火牆規則。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Remove</command:verb><command:noun>SqlFirewallRule</command:noun><dev:version /></command:details><maml:description><maml:para>停用可允許特定 SQL Server 執行個體連線的 Windows 防火牆規則。</maml:para><maml:para>SQL Server 雲端配接器必須在主控 SQL Server 執行個體的電腦上執行及存取。</maml:para><maml:para>這個 Cmdlet 支援下列作業模式:</maml:para><maml:para>1.透過指定執行個體 PowerShell 路徑。</maml:para><maml:para>2.透過指定伺服器物件。</maml:para><maml:para>3.透過指定目標 SQL Server 執行個體的 ServerInstance。</maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Remove-SqlFirewallRule</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Remove-SqlFirewallRule</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>目標執行個體的伺服器物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">Server[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Remove-SqlFirewallRule</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>此參數可指定將成為作業目標之 SQL Server 執行個體的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue><dev:type><maml:name>PSCredential</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>目標執行個體的伺服器物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">Server[]</command:parameterValue><dev:type><maml:name>Server[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>此參數可指定將成為作業目標之 SQL Server 執行個體的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>CD SQLSERVER:\SQL\Computer\Instance; Remove-SqlFirewallRule -Credential $credential -AcceptSelfSignedCertificate; </dev:code><dev:remarks><maml:para>此命令會停用電腦 'Computer' 上的 Windows 防火牆規則,以封鎖此電腦上的 SQL Server 'Instance' 之執行個體的連線。目前的工作目錄會用來決定應該進行作業的伺服器執行個體。系統會自動接受目標電腦的自我簽署憑證,而不提示使用者。</maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>This command retrieves all instances of SQL Server on the machine ‘MachineName’ and disables the Windows Firewall rules to block connections to each one of them. The self-signed certificate of the target machine will be automatically accepted without prompting the user. PS C:\>Get-SqlInstance -Credential $credential -MachineName "MachineName" | Remove-SqlFirewallRule -Credential $credential -AcceptSelfSignedCertificate; </dev:code><dev:remarks><maml:para></maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>Online Version:</maml:linkText><maml:uri></maml:uri></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Restore-SqlDatabase</command:name><maml:description><maml:para>還原所有或部分資料庫或交易記錄檔記錄的備份。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Restore</command:verb><command:noun>SqlDatabase</command:noun><dev:version /></command:details><maml:description><maml:para>Restore-SqlDatabase Cmdlet 會在 SQL Server 資料庫上執行還原作業。這包括完整資料庫還原、交易記錄還原和資料庫檔案還原。這個 Cmdlet 是依照 Microsoft.SqlServer.Management.Smo.Restore 類別建立的。此類別的參數通常會對應至該 Smo 物件的屬性。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Restore-SqlDatabase</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>要還原之資料庫的名稱。無法搭配 -DatabaseObject 參數使用。 </maml:para><maml:para>當您使用了 -Database 參數時,也必須指定 -Path、-InputObject 或 -ServerInstance 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>BackupFile</maml:name><maml:description><maml:para>儲存備份檔案的位置。這是選擇性參數。如果未指定,系統就會在伺服器的預設備份位置中搜尋 "databasename.trn" (記錄還原) 或 "databasename.bak" (所有其他還原類型) 的名稱。這個參數無法搭配 BackupDevice 參數使用。如果您要備份至 Windows Azure Blob 儲存體服務 (URL),就需要這個參數或 BackupDevice 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupDevice</maml:name><maml:description><maml:para>儲存備份的裝置。這個參數無法搭配 BackupFile 參數使用。如果您要備份至磁帶裝置,請使用此參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceItem[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BlockSize</maml:name><maml:description><maml:para>備份的實體區塊大小 (以位元組為單位)。支援的大小為 512、1024、2048、4096、8192、16384、32768 和 65536 (64 KB) 位元組。磁帶裝置的預設值為 65536,其他裝置則為 512。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BufferCount</maml:name><maml:description><maml:para>要用於備份作業的 I/O 緩衝區總數。您可以指定任何正整數。使用許多緩衝區時,可能會因為 Sqlservr.exe 處理序中的虛擬位址空間不足而造成「記憶體不足」錯誤。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Checksum</maml:name><maml:description><maml:para>在還原作業期間計算總和檢查碼值。如果未設定,則不會計算總和檢查碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ClearSuspectPageTable</maml:name><maml:description><maml:para>在還原作業後刪除可疑頁面資料表。如果未設定,就不會針對可疑頁面資料表採取任何動作。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ContinueAfterError</maml:name><maml:description><maml:para>作業會在發生總和檢查碼錯誤時繼續進行。如果未設定,則作業會在總和檢查碼錯誤之後失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFile</maml:name><maml:description><maml:para>還原作業的目標資料庫檔案。只能在 RestoreAction 屬性設定為 Files 時使用。當 RestoreAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFileGroup</maml:name><maml:description><maml:para>還原作業的目標資料庫檔案群組。只能在 RestoreAction 屬性設定為 Files 時使用。當 RestoreAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FileNumber</maml:name><maml:description><maml:para>用來識別備份媒體上目標備份組的索引編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>KeepReplication</maml:name><maml:description><maml:para>保留複寫組態。如果未設定,還原作業會忽略複寫組態。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxTransferSize</maml:name><maml:description><maml:para>要在備份媒體與 SQL Server 執行個體之間傳送的最大位元組數目。可能的值是 65536 個位元組 (64 KB) 的倍數,最多 4194304 個位元組 (4 MB)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaName</maml:name><maml:description><maml:para>用來識別特定媒體集的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRecovery</maml:name><maml:description><maml:para>資料庫會還原成還原狀態。不會進行回復。可以還原其他備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRewind</maml:name><maml:description><maml:para>當還原完成時,在結束位置讓磁帶機保持開啟狀態。如果未設定,就會在作業完成之後倒轉磁帶。不適用於磁碟還原。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Offset</maml:name><maml:description><maml:para>要還原的頁面位址。只有在 -RestoreAction 設定為 OnlinePage 時才有用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">Int64[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Partial</maml:name><maml:description><maml:para>還原作業為部分還原。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>PassThru</maml:name><maml:description><maml:para>輸出用來執行備份作業的 Smo Backup 物件。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行還原作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值會使用目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RelocateFile</maml:name><maml:description><maml:para>Smo.Relocate 檔案物件的清單。每個物件都包含邏輯備份檔案名稱以及實體檔案系統位置。還原作業會將還原的資料庫移入目標伺服器上的指定實體位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">RelocateFile[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReplaceDatabase</maml:name><maml:description><maml:para>建立資料庫的新映像。以相同名稱覆寫任何現有的資料庫。未設定時,如果已有該名稱的資料庫存在,還原作業將會失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Restart</maml:name><maml:description><maml:para>繼續處理部分完成的還原作業。如果未設定 (預設值),此 Cmdlet 就會在備份組的開頭重新啟動中斷的還原作業。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RestoreAction</maml:name><maml:description><maml:para>應該執行的還原作業類型。有效的選項包括 Database、Files、Log、OnlinePage 和 OnlineFiles。 </maml:para><maml:para>Database:還原資料庫。 </maml:para><maml:para>Files:還原一個或多個資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para><maml:para>Log:還原交易記錄。 </maml:para><maml:para>OnlinePage:在資料庫仍供其他使用者使用時,於線上還原資料頁面。 </maml:para><maml:para>OnlineFiles:在資料庫仍供其他使用者使用時,還原一個或多個資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">RestoreActionType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RestrictedUser</maml:name><maml:description><maml:para>將還原資料庫的資料庫存取權限定為 db_owner 固定資料庫角色以及 dbcreator 和系統管理員 (sysadmin) 固定伺服器角色。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>用來儲存 Windows Azure Blob 儲存體服務之驗證資訊的 SQL Server Credential。儲存的驗證資訊包含 Windows Azure 儲存體帳戶名稱和相關的存取金鑰值。如果您要從 Windows Azure Blob 儲存體服務 (URL) 還原,就需要這個參數。這個參數不能搭配 Disk 或 Tape 使用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StandbyFile</maml:name><maml:description><maml:para>恢復檔案的名稱,此檔案是 SQL Server 執行個體之映像策略的一部分。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopAtMarkAfterDate</maml:name><maml:description><maml:para>指定要與 StopAtMarkName 參數指定之標示名稱搭配使用的日期,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopAtMarkName</maml:name><maml:description><maml:para>在標示的交易之後停止復原。與 StopAtMarkAfterDate 參數搭配使用,以便決定復原作業的停止點。復原包括含有標示的交易。如果未設定 StopAtMarkAfterDate 值,復原會停在含有指定名稱的第一個標示。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopBeforeMarkAfterDate</maml:name><maml:description><maml:para>指定要與 StopBeforeMarkName 搭配使用的日期,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopBeforeMarkName</maml:name><maml:description><maml:para>在標示的交易之前停止復原。與 StopBeforeMarkAfterDate 搭配使用,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ToPointInTime</maml:name><maml:description><maml:para>資料庫記錄還原的端點。只適用於 -RestoreAction 參數設定為 Log 的情況。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UnloadTapeAfter</maml:name><maml:description><maml:para>在作業完成時倒轉並卸載磁帶裝置。如果未設定,則不會嘗試倒轉並卸載磁帶媒體。不適用於磁碟備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Restore-SqlDatabase</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>要還原之資料庫的名稱。無法搭配 -DatabaseObject 參數使用。 </maml:para><maml:para>當您使用了 -Database 參數時,也必須指定 -Path、-InputObject 或 -ServerInstance 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>BackupFile</maml:name><maml:description><maml:para>儲存備份檔案的位置。這是選擇性參數。如果未指定,系統就會在伺服器的預設備份位置中搜尋 "databasename.trn" (記錄還原) 或 "databasename.bak" (所有其他還原類型) 的名稱。這個參數無法搭配 BackupDevice 參數使用。如果您要備份至 Windows Azure Blob 儲存體服務 (URL),就需要這個參數或 BackupDevice 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupDevice</maml:name><maml:description><maml:para>儲存備份的裝置。這個參數無法搭配 BackupFile 參數使用。如果您要備份至磁帶裝置,請使用此參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceItem[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BlockSize</maml:name><maml:description><maml:para>備份的實體區塊大小 (以位元組為單位)。支援的大小為 512、1024、2048、4096、8192、16384、32768 和 65536 (64 KB) 位元組。磁帶裝置的預設值為 65536,其他裝置則為 512。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BufferCount</maml:name><maml:description><maml:para>要用於備份作業的 I/O 緩衝區總數。您可以指定任何正整數。使用許多緩衝區時,可能會因為 Sqlservr.exe 處理序中的虛擬位址空間不足而造成「記憶體不足」錯誤。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Checksum</maml:name><maml:description><maml:para>在還原作業期間計算總和檢查碼值。如果未設定,則不會計算總和檢查碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ClearSuspectPageTable</maml:name><maml:description><maml:para>在還原作業後刪除可疑頁面資料表。如果未設定,就不會針對可疑頁面資料表採取任何動作。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionTimeout</maml:name><maml:description><maml:para>在逾時失敗之前要等候伺服器連接的秒數。逾時值必須是介於 0 到 65534 之間的整數。如果指定了 0,連接嘗試就不會逾時。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ContinueAfterError</maml:name><maml:description><maml:para>作業會在發生總和檢查碼錯誤時繼續進行。如果未設定,則作業會在總和檢查碼錯誤之後失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>PSCredential 物件,其中指定有權執行此作業之 SQL Server 登入的認證。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFile</maml:name><maml:description><maml:para>還原作業的目標資料庫檔案。只能在 RestoreAction 屬性設定為 Files 時使用。當 RestoreAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFileGroup</maml:name><maml:description><maml:para>還原作業的目標資料庫檔案群組。只能在 RestoreAction 屬性設定為 Files 時使用。當 RestoreAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FileNumber</maml:name><maml:description><maml:para>用來識別備份媒體上目標備份組的索引編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>KeepReplication</maml:name><maml:description><maml:para>保留複寫組態。如果未設定,還原作業會忽略複寫組態。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxTransferSize</maml:name><maml:description><maml:para>要在備份媒體與 SQL Server 執行個體之間傳送的最大位元組數目。可能的值是 65536 個位元組 (64 KB) 的倍數,最多 4194304 個位元組 (4 MB)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaName</maml:name><maml:description><maml:para>用來識別特定媒體集的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRecovery</maml:name><maml:description><maml:para>資料庫會還原成還原狀態。不會進行回復。可以還原其他備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRewind</maml:name><maml:description><maml:para>當還原完成時,在結束位置讓磁帶機保持開啟狀態。如果未設定,就會在作業完成之後倒轉磁帶。不適用於磁碟還原。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Offset</maml:name><maml:description><maml:para>要還原的頁面位址。只有在 -RestoreAction 設定為 OnlinePage 時才有用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">Int64[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Partial</maml:name><maml:description><maml:para>還原作業為部分還原。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>PassThru</maml:name><maml:description><maml:para>輸出用來執行備份作業的 Smo Backup 物件。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RelocateFile</maml:name><maml:description><maml:para>Smo.Relocate 檔案物件的清單。每個物件都包含邏輯備份檔案名稱以及實體檔案系統位置。還原作業會將還原的資料庫移入目標伺服器上的指定實體位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">RelocateFile[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReplaceDatabase</maml:name><maml:description><maml:para>建立資料庫的新映像。以相同名稱覆寫任何現有的資料庫。未設定時,如果已有該名稱的資料庫存在,還原作業將會失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Restart</maml:name><maml:description><maml:para>繼續處理部分完成的還原作業。如果未設定 (預設值),此 Cmdlet 就會在備份組的開頭重新啟動中斷的還原作業。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RestoreAction</maml:name><maml:description><maml:para>應該執行的還原作業類型。有效的選項包括 Database、Files、Log、OnlinePage 和 OnlineFiles。 </maml:para><maml:para>Database:還原資料庫。 </maml:para><maml:para>Files:還原一個或多個資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para><maml:para>Log:還原交易記錄。 </maml:para><maml:para>OnlinePage:在資料庫仍供其他使用者使用時,於線上還原資料頁面。 </maml:para><maml:para>OnlineFiles:在資料庫仍供其他使用者使用時,還原一個或多個資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">RestoreActionType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RestrictedUser</maml:name><maml:description><maml:para>將還原資料庫的資料庫存取權限定為 db_owner 固定資料庫角色以及 dbcreator 和系統管理員 (sysadmin) 固定伺服器角色。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>用來儲存 Windows Azure Blob 儲存體服務之驗證資訊的 SQL Server Credential。儲存的驗證資訊包含 Windows Azure 儲存體帳戶名稱和相關的存取金鑰值。如果您要從 Windows Azure Blob 儲存體服務 (URL) 還原,就需要這個參數。這個參數不能搭配 Disk 或 Tape 使用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StandbyFile</maml:name><maml:description><maml:para>恢復檔案的名稱,此檔案是 SQL Server 執行個體之映像策略的一部分。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopAtMarkAfterDate</maml:name><maml:description><maml:para>指定要與 StopAtMarkName 參數指定之標示名稱搭配使用的日期,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopAtMarkName</maml:name><maml:description><maml:para>在標示的交易之後停止復原。與 StopAtMarkAfterDate 參數搭配使用,以便決定復原作業的停止點。復原包括含有標示的交易。如果未設定 StopAtMarkAfterDate 值,復原會停在含有指定名稱的第一個標示。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopBeforeMarkAfterDate</maml:name><maml:description><maml:para>指定要與 StopBeforeMarkName 搭配使用的日期,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopBeforeMarkName</maml:name><maml:description><maml:para>在標示的交易之前停止復原。與 StopBeforeMarkAfterDate 搭配使用,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ToPointInTime</maml:name><maml:description><maml:para>資料庫記錄還原的端點。只適用於 -RestoreAction 參數設定為 Log 的情況。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UnloadTapeAfter</maml:name><maml:description><maml:para>在作業完成時倒轉並卸載磁帶裝置。如果未設定,則不會嘗試倒轉並卸載磁帶媒體。不適用於磁碟備份。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>SQL Server 執行個體的名稱。這個伺服器執行個體會成為還原作業的目標。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Restore-SqlDatabase</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>要還原之資料庫的名稱。無法搭配 -DatabaseObject 參數使用。 </maml:para><maml:para>當您使用了 -Database 參數時,也必須指定 -Path、-InputObject 或 -ServerInstance 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>BackupFile</maml:name><maml:description><maml:para>儲存備份檔案的位置。這是選擇性參數。如果未指定,系統就會在伺服器的預設備份位置中搜尋 "databasename.trn" (記錄還原) 或 "databasename.bak" (所有其他還原類型) 的名稱。這個參數無法搭配 BackupDevice 參數使用。如果您要備份至 Windows Azure Blob 儲存體服務 (URL),就需要這個參數或 BackupDevice 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupDevice</maml:name><maml:description><maml:para>儲存備份的裝置。這個參數無法搭配 BackupFile 參數使用。如果您要備份至磁帶裝置,請使用此參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceItem[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BlockSize</maml:name><maml:description><maml:para>備份的實體區塊大小 (以位元組為單位)。支援的大小為 512、1024、2048、4096、8192、16384、32768 和 65536 (64 KB) 位元組。磁帶裝置的預設值為 65536,其他裝置則為 512。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BufferCount</maml:name><maml:description><maml:para>要用於備份作業的 I/O 緩衝區總數。您可以指定任何正整數。使用許多緩衝區時,可能會因為 Sqlservr.exe 處理序中的虛擬位址空間不足而造成「記憶體不足」錯誤。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Checksum</maml:name><maml:description><maml:para>在還原作業期間計算總和檢查碼值。如果未設定,則不會計算總和檢查碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ClearSuspectPageTable</maml:name><maml:description><maml:para>在還原作業後刪除可疑頁面資料表。如果未設定,就不會針對可疑頁面資料表採取任何動作。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ContinueAfterError</maml:name><maml:description><maml:para>作業會在發生總和檢查碼錯誤時繼續進行。如果未設定,則作業會在總和檢查碼錯誤之後失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFile</maml:name><maml:description><maml:para>還原作業的目標資料庫檔案。只能在 RestoreAction 屬性設定為 Files 時使用。當 RestoreAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFileGroup</maml:name><maml:description><maml:para>還原作業的目標資料庫檔案群組。只能在 RestoreAction 屬性設定為 Files 時使用。當 RestoreAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FileNumber</maml:name><maml:description><maml:para>用來識別備份媒體上目標備份組的索引編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>KeepReplication</maml:name><maml:description><maml:para>保留複寫組態。如果未設定,還原作業會忽略複寫組態。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxTransferSize</maml:name><maml:description><maml:para>要在備份媒體與 SQL Server 執行個體之間傳送的最大位元組數目。可能的值是 65536 個位元組 (64 KB) 的倍數,最多 4194304 個位元組 (4 MB)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaName</maml:name><maml:description><maml:para>用來識別特定媒體集的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRecovery</maml:name><maml:description><maml:para>資料庫會還原成還原狀態。不會進行回復。可以還原其他備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRewind</maml:name><maml:description><maml:para>當還原完成時,在結束位置讓磁帶機保持開啟狀態。如果未設定,就會在作業完成之後倒轉磁帶。不適用於磁碟還原。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Offset</maml:name><maml:description><maml:para>要還原的頁面位址。只有在 -RestoreAction 設定為 OnlinePage 時才有用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">Int64[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Partial</maml:name><maml:description><maml:para>還原作業為部分還原。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>PassThru</maml:name><maml:description><maml:para>輸出用來執行備份作業的 Smo Backup 物件。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RelocateFile</maml:name><maml:description><maml:para>Smo.Relocate 檔案物件的清單。每個物件都包含邏輯備份檔案名稱以及實體檔案系統位置。還原作業會將還原的資料庫移入目標伺服器上的指定實體位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">RelocateFile[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReplaceDatabase</maml:name><maml:description><maml:para>建立資料庫的新映像。以相同名稱覆寫任何現有的資料庫。未設定時,如果已有該名稱的資料庫存在,還原作業將會失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Restart</maml:name><maml:description><maml:para>繼續處理部分完成的還原作業。如果未設定 (預設值),此 Cmdlet 就會在備份組的開頭重新啟動中斷的還原作業。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RestoreAction</maml:name><maml:description><maml:para>應該執行的還原作業類型。有效的選項包括 Database、Files、Log、OnlinePage 和 OnlineFiles。 </maml:para><maml:para>Database:還原資料庫。 </maml:para><maml:para>Files:還原一個或多個資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para><maml:para>Log:還原交易記錄。 </maml:para><maml:para>OnlinePage:在資料庫仍供其他使用者使用時,於線上還原資料頁面。 </maml:para><maml:para>OnlineFiles:在資料庫仍供其他使用者使用時,還原一個或多個資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">RestoreActionType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RestrictedUser</maml:name><maml:description><maml:para>將還原資料庫的資料庫存取權限定為 db_owner 固定資料庫角色以及 dbcreator 和系統管理員 (sysadmin) 固定伺服器角色。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>用來儲存 Windows Azure Blob 儲存體服務之驗證資訊的 SQL Server Credential。儲存的驗證資訊包含 Windows Azure 儲存體帳戶名稱和相關的存取金鑰值。如果您要從 Windows Azure Blob 儲存體服務 (URL) 還原,就需要這個參數。這個參數不能搭配 Disk 或 Tape 使用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StandbyFile</maml:name><maml:description><maml:para>恢復檔案的名稱,此檔案是 SQL Server 執行個體之映像策略的一部分。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopAtMarkAfterDate</maml:name><maml:description><maml:para>指定要與 StopAtMarkName 參數指定之標示名稱搭配使用的日期,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopAtMarkName</maml:name><maml:description><maml:para>在標示的交易之後停止復原。與 StopAtMarkAfterDate 參數搭配使用,以便決定復原作業的停止點。復原包括含有標示的交易。如果未設定 StopAtMarkAfterDate 值,復原會停在含有指定名稱的第一個標示。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopBeforeMarkAfterDate</maml:name><maml:description><maml:para>指定要與 StopBeforeMarkName 搭配使用的日期,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopBeforeMarkName</maml:name><maml:description><maml:para>在標示的交易之前停止復原。與 StopBeforeMarkAfterDate 搭配使用,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ToPointInTime</maml:name><maml:description><maml:para>資料庫記錄還原的端點。只適用於 -RestoreAction 參數設定為 Log 的情況。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UnloadTapeAfter</maml:name><maml:description><maml:para>在作業完成時倒轉並卸載磁帶裝置。如果未設定,則不會嘗試倒轉並卸載磁帶媒體。不適用於磁碟備份。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該進行還原之 SQL Server 執行個體的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">Server[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Restore-SqlDatabase</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>DatabaseObject</maml:name><maml:description><maml:para>資料庫物件。還原作業會將備份還原至這個資料庫。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Database</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>BackupFile</maml:name><maml:description><maml:para>儲存備份檔案的位置。這是選擇性參數。如果未指定,系統就會在伺服器的預設備份位置中搜尋 "databasename.trn" (記錄還原) 或 "databasename.bak" (所有其他還原類型) 的名稱。這個參數無法搭配 BackupDevice 參數使用。如果您要備份至 Windows Azure Blob 儲存體服務 (URL),就需要這個參數或 BackupDevice 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupDevice</maml:name><maml:description><maml:para>儲存備份的裝置。這個參數無法搭配 BackupFile 參數使用。如果您要備份至磁帶裝置,請使用此參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceItem[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BlockSize</maml:name><maml:description><maml:para>備份的實體區塊大小 (以位元組為單位)。支援的大小為 512、1024、2048、4096、8192、16384、32768 和 65536 (64 KB) 位元組。磁帶裝置的預設值為 65536,其他裝置則為 512。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BufferCount</maml:name><maml:description><maml:para>要用於備份作業的 I/O 緩衝區總數。您可以指定任何正整數。使用許多緩衝區時,可能會因為 Sqlservr.exe 處理序中的虛擬位址空間不足而造成「記憶體不足」錯誤。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Checksum</maml:name><maml:description><maml:para>在還原作業期間計算總和檢查碼值。如果未設定,則不會計算總和檢查碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ClearSuspectPageTable</maml:name><maml:description><maml:para>在還原作業後刪除可疑頁面資料表。如果未設定,就不會針對可疑頁面資料表採取任何動作。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ContinueAfterError</maml:name><maml:description><maml:para>作業會在發生總和檢查碼錯誤時繼續進行。如果未設定,則作業會在總和檢查碼錯誤之後失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFile</maml:name><maml:description><maml:para>還原作業的目標資料庫檔案。只能在 RestoreAction 屬性設定為 Files 時使用。當 RestoreAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFileGroup</maml:name><maml:description><maml:para>還原作業的目標資料庫檔案群組。只能在 RestoreAction 屬性設定為 Files 時使用。當 RestoreAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FileNumber</maml:name><maml:description><maml:para>用來識別備份媒體上目標備份組的索引編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>KeepReplication</maml:name><maml:description><maml:para>保留複寫組態。如果未設定,還原作業會忽略複寫組態。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxTransferSize</maml:name><maml:description><maml:para>要在備份媒體與 SQL Server 執行個體之間傳送的最大位元組數目。可能的值是 65536 個位元組 (64 KB) 的倍數,最多 4194304 個位元組 (4 MB)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaName</maml:name><maml:description><maml:para>用來識別特定媒體集的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRecovery</maml:name><maml:description><maml:para>資料庫會還原成還原狀態。不會進行回復。可以還原其他備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRewind</maml:name><maml:description><maml:para>當還原完成時,在結束位置讓磁帶機保持開啟狀態。如果未設定,就會在作業完成之後倒轉磁帶。不適用於磁碟還原。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Offset</maml:name><maml:description><maml:para>要還原的頁面位址。只有在 -RestoreAction 設定為 OnlinePage 時才有用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">Int64[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Partial</maml:name><maml:description><maml:para>還原作業為部分還原。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>PassThru</maml:name><maml:description><maml:para>輸出用來執行備份作業的 Smo Backup 物件。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RelocateFile</maml:name><maml:description><maml:para>Smo.Relocate 檔案物件的清單。每個物件都包含邏輯備份檔案名稱以及實體檔案系統位置。還原作業會將還原的資料庫移入目標伺服器上的指定實體位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">RelocateFile[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReplaceDatabase</maml:name><maml:description><maml:para>建立資料庫的新映像。以相同名稱覆寫任何現有的資料庫。未設定時,如果已有該名稱的資料庫存在,還原作業將會失敗。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Restart</maml:name><maml:description><maml:para>繼續處理部分完成的還原作業。如果未設定 (預設值),此 Cmdlet 就會在備份組的開頭重新啟動中斷的還原作業。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RestoreAction</maml:name><maml:description><maml:para>應該執行的還原作業類型。有效的選項包括 Database、Files、Log、OnlinePage 和 OnlineFiles。 </maml:para><maml:para>Database:還原資料庫。 </maml:para><maml:para>Files:還原一個或多個資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para><maml:para>Log:還原交易記錄。 </maml:para><maml:para>OnlinePage:在資料庫仍供其他使用者使用時,於線上還原資料頁面。 </maml:para><maml:para>OnlineFiles:在資料庫仍供其他使用者使用時,還原一個或多個資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">RestoreActionType</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RestrictedUser</maml:name><maml:description><maml:para>將還原資料庫的資料庫存取權限定為 db_owner 固定資料庫角色以及 dbcreator 和系統管理員 (sysadmin) 固定伺服器角色。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>用來儲存 Windows Azure Blob 儲存體服務之驗證資訊的 SQL Server Credential。儲存的驗證資訊包含 Windows Azure 儲存體帳戶名稱和相關的存取金鑰值。如果您要從 Windows Azure Blob 儲存體服務 (URL) 還原,就需要這個參數。這個參數不能搭配 Disk 或 Tape 使用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StandbyFile</maml:name><maml:description><maml:para>恢復檔案的名稱,此檔案是 SQL Server 執行個體之映像策略的一部分。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopAtMarkAfterDate</maml:name><maml:description><maml:para>指定要與 StopAtMarkName 參數指定之標示名稱搭配使用的日期,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopAtMarkName</maml:name><maml:description><maml:para>在標示的交易之後停止復原。與 StopAtMarkAfterDate 參數搭配使用,以便決定復原作業的停止點。復原包括含有標示的交易。如果未設定 StopAtMarkAfterDate 值,復原會停在含有指定名稱的第一個標示。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopBeforeMarkAfterDate</maml:name><maml:description><maml:para>指定要與 StopBeforeMarkName 搭配使用的日期,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopBeforeMarkName</maml:name><maml:description><maml:para>在標示的交易之前停止復原。與 StopBeforeMarkAfterDate 搭配使用,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ToPointInTime</maml:name><maml:description><maml:para>資料庫記錄還原的端點。只適用於 -RestoreAction 參數設定為 Log 的情況。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UnloadTapeAfter</maml:name><maml:description><maml:para>在作業完成時倒轉並卸載磁帶裝置。如果未設定,則不會嘗試倒轉並卸載磁帶媒體。不適用於磁碟備份。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupDevice</maml:name><maml:description><maml:para>儲存備份的裝置。這個參數無法搭配 BackupFile 參數使用。如果您要備份至磁帶裝置,請使用此參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">BackupDeviceItem[]</command:parameterValue><dev:type><maml:name>BackupDeviceItem[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>BackupFile</maml:name><maml:description><maml:para>儲存備份檔案的位置。這是選擇性參數。如果未指定,系統就會在伺服器的預設備份位置中搜尋 "databasename.trn" (記錄還原) 或 "databasename.bak" (所有其他還原類型) 的名稱。這個參數無法搭配 BackupDevice 參數使用。如果您要備份至 Windows Azure Blob 儲存體服務 (URL),就需要這個參數或 BackupDevice 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BlockSize</maml:name><maml:description><maml:para>備份的實體區塊大小 (以位元組為單位)。支援的大小為 512、1024、2048、4096、8192、16384、32768 和 65536 (64 KB) 位元組。磁帶裝置的預設值為 65536,其他裝置則為 512。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BufferCount</maml:name><maml:description><maml:para>要用於備份作業的 I/O 緩衝區總數。您可以指定任何正整數。使用許多緩衝區時,可能會因為 Sqlservr.exe 處理序中的虛擬位址空間不足而造成「記憶體不足」錯誤。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Checksum</maml:name><maml:description><maml:para>在還原作業期間計算總和檢查碼值。如果未設定,則不會計算總和檢查碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ClearSuspectPageTable</maml:name><maml:description><maml:para>在還原作業後刪除可疑頁面資料表。如果未設定,就不會針對可疑頁面資料表採取任何動作。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionTimeout</maml:name><maml:description><maml:para>在逾時失敗之前要等候伺服器連接的秒數。逾時值必須是介於 0 到 65534 之間的整數。如果指定了 0,連接嘗試就不會逾時。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ContinueAfterError</maml:name><maml:description><maml:para>作業會在發生總和檢查碼錯誤時繼續進行。如果未設定,則作業會在總和檢查碼錯誤之後失敗。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>PSCredential 物件,其中指定有權執行此作業之 SQL Server 登入的認證。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue><dev:type><maml:name>PSCredential</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Database</maml:name><maml:description><maml:para>要還原之資料庫的名稱。無法搭配 -DatabaseObject 參數使用。 </maml:para><maml:para>當您使用了 -Database 參數時,也必須指定 -Path、-InputObject 或 -ServerInstance 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFile</maml:name><maml:description><maml:para>還原作業的目標資料庫檔案。只能在 RestoreAction 屬性設定為 Files 時使用。當 RestoreAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>DatabaseFileGroup</maml:name><maml:description><maml:para>還原作業的目標資料庫檔案群組。只能在 RestoreAction 屬性設定為 Files 時使用。當 RestoreAction 參數設定為 Files 時,您就必須指定 DatabaseFileGroups 屬性或 DatabaseFiles 屬性。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>DatabaseObject</maml:name><maml:description><maml:para>資料庫物件。還原作業會將備份還原至這個資料庫。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Database</command:parameterValue><dev:type><maml:name>Database</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FileNumber</maml:name><maml:description><maml:para>用來識別備份媒體上目標備份組的索引編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該進行還原之 SQL Server 執行個體的 Server 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">Server[]</command:parameterValue><dev:type><maml:name>Server[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>KeepReplication</maml:name><maml:description><maml:para>保留複寫組態。如果未設定,還原作業會忽略複寫組態。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MaxTransferSize</maml:name><maml:description><maml:para>要在備份媒體與 SQL Server 執行個體之間傳送的最大位元組數目。可能的值是 65536 個位元組 (64 KB) 的倍數,最多 4194304 個位元組 (4 MB)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MediaName</maml:name><maml:description><maml:para>用來識別特定媒體集的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRecovery</maml:name><maml:description><maml:para>資料庫會還原成還原狀態。不會進行回復。可以還原其他備份。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoRewind</maml:name><maml:description><maml:para>當還原完成時,在結束位置讓磁帶機保持開啟狀態。如果未設定,就會在作業完成之後倒轉磁帶。不適用於磁碟還原。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Offset</maml:name><maml:description><maml:para>要還原的頁面位址。只有在 -RestoreAction 設定為 OnlinePage 時才有用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">Int64[]</command:parameterValue><dev:type><maml:name>Int64[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Partial</maml:name><maml:description><maml:para>還原作業為部分還原。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>PassThru</maml:name><maml:description><maml:para>輸出用來執行備份作業的 Smo Backup 物件。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行還原作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值會使用目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RelocateFile</maml:name><maml:description><maml:para>Smo.Relocate 檔案物件的清單。每個物件都包含邏輯備份檔案名稱以及實體檔案系統位置。還原作業會將還原的資料庫移入目標伺服器上的指定實體位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">RelocateFile[]</command:parameterValue><dev:type><maml:name>RelocateFile[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReplaceDatabase</maml:name><maml:description><maml:para>建立資料庫的新映像。以相同名稱覆寫任何現有的資料庫。未設定時,如果已有該名稱的資料庫存在,還原作業將會失敗。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Restart</maml:name><maml:description><maml:para>繼續處理部分完成的還原作業。如果未設定 (預設值),此 Cmdlet 就會在備份組的開頭重新啟動中斷的還原作業。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RestoreAction</maml:name><maml:description><maml:para>應該執行的還原作業類型。有效的選項包括 Database、Files、Log、OnlinePage 和 OnlineFiles。 </maml:para><maml:para>Database:還原資料庫。 </maml:para><maml:para>Files:還原一個或多個資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para><maml:para>Log:還原交易記錄。 </maml:para><maml:para>OnlinePage:在資料庫仍供其他使用者使用時,於線上還原資料頁面。 </maml:para><maml:para>OnlineFiles:在資料庫仍供其他使用者使用時,還原一個或多個資料檔案。這個選項需要設定 DatabaseFile 或 DatabaseFileGroup 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">RestoreActionType</command:parameterValue><dev:type><maml:name>RestoreActionType</maml:name><maml:uri /></dev:type><dev:defaultValue>Microsoft.SqlServer.Management.Smo.RestoreActionType.Database</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RestrictedUser</maml:name><maml:description><maml:para>將還原資料庫的資料庫存取權限定為 db_owner 固定資料庫角色以及 dbcreator 和系統管理員 (sysadmin) 固定伺服器角色。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>SQL Server 執行個體的名稱。這個伺服器執行個體會成為還原作業的目標。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>用來儲存 Windows Azure Blob 儲存體服務之驗證資訊的 SQL Server Credential。儲存的驗證資訊包含 Windows Azure 儲存體帳戶名稱和相關的存取金鑰值。如果您要從 Windows Azure Blob 儲存體服務 (URL) 還原,就需要這個參數。這個參數不能搭配 Disk 或 Tape 使用。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue><dev:type><maml:name>PSObject</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StandbyFile</maml:name><maml:description><maml:para>恢復檔案的名稱,此檔案是 SQL Server 執行個體之映像策略的一部分。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopAtMarkAfterDate</maml:name><maml:description><maml:para>指定要與 StopAtMarkName 參數指定之標示名稱搭配使用的日期,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopAtMarkName</maml:name><maml:description><maml:para>在標示的交易之後停止復原。與 StopAtMarkAfterDate 參數搭配使用,以便決定復原作業的停止點。復原包括含有標示的交易。如果未設定 StopAtMarkAfterDate 值,復原會停在含有指定名稱的第一個標示。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopBeforeMarkAfterDate</maml:name><maml:description><maml:para>指定要與 StopBeforeMarkName 搭配使用的日期,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>StopBeforeMarkName</maml:name><maml:description><maml:para>在標示的交易之前停止復原。與 StopBeforeMarkAfterDate 搭配使用,以便決定復原作業的停止點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ToPointInTime</maml:name><maml:description><maml:para>資料庫記錄還原的端點。只適用於 -RestoreAction 參數設定為 Log 的情況。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>UnloadTapeAfter</maml:name><maml:description><maml:para>在作業完成時倒轉並卸載磁帶裝置。如果未設定,則不會嘗試倒轉並卸載磁帶媒體。不適用於磁碟備份。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Smo.Server</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 參考應該進行還原作業之 SQL Server 執行個體的 SMO.Server 物件。 </maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Restore-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -BackupFile "\\share\folder\MyDB.bak" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將完整資料庫 'MyDB' 從檔案 '\\share\folder\MyDB.bak' 還原至伺服器執行個體 'Computer\Instance'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Restore-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -BackupFile "\\share\folder\MyDB.trn" -RestoreAction Log </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將資料庫 'MyDB' 的交易記錄從檔案 '\\share\folder\MyDB.trn' 還原至伺服器執行個體 'Computer\Instance'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Restore-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -BackupFile "\\share\folder\MyDB.bak" -Credential (Get-Credential sa) </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會使用 sa SQL 登入,將完整資料庫 'MyDB' 從檔案 '\\share\folder\MyDB.trn' 還原至伺服器執行個體 'Computer\Instance'。此命令將提示您輸入密碼以完成 SQL 驗證。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 4 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Restore-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -BackupFile "\\share\folder\MyDB.trn" -RestoreAction Log -NoRecovery </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會使用 NORECOVERY 選項,將資料庫 'MyDB' 的交易記錄從檔案 '\\share\folder\MyDB.trn' 還原至伺服器執行個體 'Computer\Instance'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 5 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Restore-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -BackupFile "\\share\folder\MyDB.trn" -RestoreAction Log -ToPointInTime "Nov 11, 2011 11:11 AM" </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會還原資料庫 'MyDB' 的交易記錄,還原範圍截至傳遞給 -ToPointInTime 參數的日期 'Nov 11, 2011 11:11 AM' 為止。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 6 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$RelocateData = New-Object Microsoft.SqlServer.Management.Smo.RelocateFile("MyDB_Data", "c:\MySQLServer\MyDB.mdf") $RelocateLog = New-Object Microsoft.SqlServer.Management.Smo.RelocateFile("MyDB_Log", "c:\MySQLServer\MyDB.ldf") Restore-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -BackupFile "\\share\folder\MyDB.trn" -RelocateFile @($RelocateData,$RelocateLog) </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會將完整資料庫 'MyDB' 還原至伺服器執行個體 'Computer\Instance',並且重新放置資料和記錄檔。此範例會針對要移動的每個檔案建構 Microsoft.SqlServer.Management.Smo.RelocateFile 的執行個體:'$RelocateData' 和 '$RelocateLog'。每個建構函式都可接受兩個引數:檔案的邏輯名稱以及將在目標伺服器上放置檔案的實體位置。這些 RelocateFile 物件會傳遞給 Restore-SqlDatabase Cmdlet 的 -RelocateFile 參數。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 7 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>$tapeDevice = New-Object Microsoft.Sqlserver.Management.Smo.BackupDeviceItem("\\.\tape0", "Tape") Restore-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -BackupDevice $tapeDevice </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會將資料庫 'MyDB' 從名為 '\\.\tape0' 的磁帶裝置還原至伺服器執行個體 'Computer\Instance'。為了表示這個裝置,此範例會建構 Microsoft.Sqlserver.Management.Smo.BackupDeviceItem 的執行個體。該建構函式可接受兩個引數:備份裝置的名稱 ('\\.\tape0') 以及備份裝置的類型 ('Tape')。然後,這個 BackupDeviceItem 物件會傳遞給 Restore-SqlDatabase Cmdlet 的 -BackupDevice 參數。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 8 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>Restore-SqlDatabase -ServerInstance Computer\Instance -Database MyDB -BackupFile "https://mystorageaccountname.blob.core.windows.net/container/MyDB.bak" https://mystorageaccountname.blob.core.windows.net/container/MyDB.bak" -SqlCredential "mySqlCredential" </dev:code><dev:remarks><maml:para>此命令會將完整資料庫 'MyDB' 從 Windows Azure Blob 儲存體服務上的檔案還原至伺服器執行個體 'computer\Instance'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Resume-SqlAvailabilityDatabase</command:name><maml:description><maml:para>繼續進行可用性資料庫的資料移動。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Resume</command:verb><command:noun>SqlAvailabilityDatabase</command:noun><dev:version /></command:details><maml:description><maml:para>Resume-SqlAvailabilityDatabase Cmdlet 會繼續進行可用性資料庫的資料移動。繼續進行主要資料庫時,就會繼續進行對應次要資料庫的資料移動。繼續進行特定次要資料庫時,只會繼續進行該資料庫的資料移動。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Resume-SqlAvailabilityDatabase</maml:name><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性資料庫的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Resume-SqlAvailabilityDatabase</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>要繼續進行資料移動之主要或次要資料庫的 AvailabilityDatabase 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>要繼續進行資料移動之主要或次要資料庫的 AvailabilityDatabase 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Target</command:parameterValue><dev:type><maml:name>Target</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性資料庫的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.AvailabilityDatabase</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name>SQL Server Books Online: Resuming a Database in an Availability Group (SQL Server)</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Resume-SqlAvailabilityDatabase -Path SQLSERVER:\Sql\Computer\Instance\AvailabilityGroups\MyAg\AvailabilityDatabases\MyDatabase </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會針對可用性群組 'MyAg' 中的可用性資料庫 'MyDatabase' 繼續進行資料同步處理。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>dir SQLSERVER:\Sql\Computer\Instance\AvailabilityGroups\AgName\AvailabilityDatabases | Resume-SqlAvailabilityDatabase </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會針對伺服器執行個體 'Computer\Instance' 上可用性群組 'MyAg' 中的所有可用性資料庫繼續進行資料同步處理。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Resume-SqlAvailabilityDatabase -Path SQLSERVER:\Sql\Computer\Instance\AvailabilityGroups\MyAg\AvailabilityDatabases\MyDatabase -Script </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會輸出 Transact-SQL 指令碼,這個指令碼會針對伺服器執行個體 'Computer\Instance' 上可用性群組 'MyAg' 中的可用性資料庫 'MyDatabase' 繼續進行資料同步處理。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Set-SqlAuthenticationMode</command:name><maml:description><maml:para>設定目標 SQL Server 執行個體的驗證模式。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Set</command:verb><command:noun>SqlAuthenticationMode</command:noun><dev:version /></command:details><maml:description><maml:para>設定目標 SQL Server 執行個體的驗證模式。</maml:para><maml:para>SQL Server 雲端配接器必須在主控 SQL Server 執行個體的電腦上執行及存取。</maml:para><maml:para>這個 Cmdlet 支援下列作業模式:</maml:para><maml:para>1.透過指定執行個體 PowerShell 路徑。</maml:para><maml:para>2.透過指定伺服器物件。</maml:para><maml:para>3.透過指定目標 SQL Server 執行個體的 ServerInstance。</maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Set-SqlAuthenticationMode</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Mode</maml:name><maml:description><maml:para>在目標 SQL Server 執行個體上設定的驗證模式。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">ServerLoginMode</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>啟用「混合模式」驗證時,在目標 SQL Server 執行個體上建立的系統管理員認證。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ForceServiceRestart</maml:name><maml:description><maml:para>必要時,強制重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>避免重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Set-SqlAuthenticationMode</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Mode</maml:name><maml:description><maml:para>在目標 SQL Server 執行個體上設定的驗證模式。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">ServerLoginMode</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>啟用「混合模式」驗證時,在目標 SQL Server 執行個體上建立的系統管理員認證。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ForceServiceRestart</maml:name><maml:description><maml:para>必要時,強制重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>避免重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>目標執行個體的伺服器物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">Server[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Set-SqlAuthenticationMode</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Mode</maml:name><maml:description><maml:para>在目標 SQL Server 執行個體上設定的驗證模式。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">ServerLoginMode</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>啟用「混合模式」驗證時,在目標 SQL Server 執行個體上建立的系統管理員認證。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ForceServiceRestart</maml:name><maml:description><maml:para>必要時,強制重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>避免重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>此參數可指定將成為作業目標之 SQL Server 執行個體的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue><dev:type><maml:name>PSCredential</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ForceServiceRestart</maml:name><maml:description><maml:para>必要時,強制重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>目標執行個體的伺服器物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">Server[]</command:parameterValue><dev:type><maml:name>Server[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Mode</maml:name><maml:description><maml:para>在目標 SQL Server 執行個體上設定的驗證模式。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">ServerLoginMode</command:parameterValue><dev:type><maml:name>ServerLoginMode</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>避免重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>此參數可指定將成為作業目標之 SQL Server 執行個體的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>啟用「混合模式」驗證時,在目標 SQL Server 執行個體上建立的系統管理員認證。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue><dev:type><maml:name>PSCredential</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>CD SQLSERVER:\SQL\Computer\Instance; Set-SqlAuthenticationMode -Credential $credential Integrated -ForceServiceRestart -AcceptSelfSignedCertificate; </dev:code><dev:remarks><maml:para>此命令會將伺服器執行個體 'Computer\Instance' 的驗證模式設定為 'Integrated'。目前的工作目錄會用來決定應該進行作業的伺服器執行個體。SQL Server 服務將會自動重新啟動,而不提示使用者。系統會自動接受目標電腦的自我簽署憑證,而不提示使用者。</maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>This command retrieves all instances of SQL Server on the machine ‘MachineName’ and configures the authentication mode to ‘Mixed’, with the provided SQL credentials for each one of them. The SQL Server service will not be restarted automatically. The self-signed certificate of the target machine will be automatically accepted without prompting the user. PS C:\>Get-SqlInstance -Credential $credential -MachineName "MachineName" | Set-SqlAuthenticationMode -Credential $credential -Mode Mixed -SqlCredential $sqlCredential -NoServiceRestart -AcceptSelfSignedCertificate; </dev:code><dev:remarks><maml:para></maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>Online Version:</maml:linkText><maml:uri></maml:uri></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Set-SqlAvailabilityGroup</command:name><maml:description><maml:para>這個 Cmdlet 會修改現有可用性群組的設定。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Set</command:verb><command:noun>SqlAvailabilityGroup</command:noun><dev:version /></command:details><maml:description><maml:para>Set-SqlAvailabilityGroup Cmdlet 會修改現有可用性群組的 AutomatedBackupPreference、FailureConditionLevel 和 HealthCheckTimeout 設定。這個 Cmdlet 只能在裝載主要複本的伺服器執行個體上執行。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Set-SqlAvailabilityGroup</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AutomatedBackupPreference</maml:name><maml:description><maml:para>可用性群組的自動備份喜好設定。有效的選項包括: </maml:para><maml:para>Primary:指定備份一定要在主要複本上進行,不論其所在位置為何。這通常是因為使用者需要在次要複本上執行備份時無法使用的功能,例如差異備份。 </maml:para><maml:para>SecondaryOnly:指定絕對不能在主要複本上執行備份。如果主要複本是唯一的線上複本,就不會進行備份。 </maml:para><maml:para>Secondary:指定除非主要複本是唯一的線上複本,否則備份會在次要複本上進行。然後,備份會在主要複本上進行。 </maml:para><maml:para>None:此選項會指定您在選擇要執行備份的複本時,不想要將主要/次要狀態納入考量。只考慮 BackupPriority 以及上線/已連接狀態等因素。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityGroupAutomatedBackupPreference</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailureConditionLevel</maml:name><maml:description><maml:para>決定可用性群組的自動容錯移轉行為。有效的選項包括: </maml:para><maml:para>OnServerDown:SQL Server 服務停止時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnServerUnresponsive:滿足任何狀況的較低值,而且 SQL Server 服務連接到叢集且超過 "HealthCheckTimeout" 臨界值,或者目前位於主要角色中的可用性複本處於失敗狀態時,便容錯移轉或重新啟動 (請參閱 HealthCheckTimeout 參數)。 </maml:para><maml:para>OnCriticalServerError:滿足任何狀況的較低值,而且發生內部嚴重伺服器錯誤 (記憶體不足的狀況、嚴重的寫入存取違規或傾印過多) 時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnModerateServerError:滿足任何狀況的較低值,而且發生一般伺服器錯誤 (持續的記憶體不足狀況) 時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnAnyQualifiedFailureConditions:滿足任何狀況的較低值,而且發生限定失敗狀況 (引擎工作者執行緒已耗盡、偵測到無法解決的死結) 時,便容錯移轉或重新啟動。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityGroupFailureConditionLevel</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>HealthCheckTimeout</maml:name><maml:description><maml:para>將沒有回應的伺服器宣告為狀況不良之前經過的時間長度 (以毫秒為單位)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Set-SqlAvailabilityGroup</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>要修改之可用性群組的 AvailabilityGroup 物件。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AutomatedBackupPreference</maml:name><maml:description><maml:para>可用性群組的自動備份喜好設定。有效的選項包括: </maml:para><maml:para>Primary:指定備份一定要在主要複本上進行,不論其所在位置為何。這通常是因為使用者需要在次要複本上執行備份時無法使用的功能,例如差異備份。 </maml:para><maml:para>SecondaryOnly:指定絕對不能在主要複本上執行備份。如果主要複本是唯一的線上複本,就不會進行備份。 </maml:para><maml:para>Secondary:指定除非主要複本是唯一的線上複本,否則備份會在次要複本上進行。然後,備份會在主要複本上進行。 </maml:para><maml:para>None:此選項會指定您在選擇要執行備份的複本時,不想要將主要/次要狀態納入考量。只考慮 BackupPriority 以及上線/已連接狀態等因素。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityGroupAutomatedBackupPreference</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailureConditionLevel</maml:name><maml:description><maml:para>決定可用性群組的自動容錯移轉行為。有效的選項包括: </maml:para><maml:para>OnServerDown:SQL Server 服務停止時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnServerUnresponsive:滿足任何狀況的較低值,而且 SQL Server 服務連接到叢集且超過 "HealthCheckTimeout" 臨界值,或者目前位於主要角色中的可用性複本處於失敗狀態時,便容錯移轉或重新啟動 (請參閱 HealthCheckTimeout 參數)。 </maml:para><maml:para>OnCriticalServerError:滿足任何狀況的較低值,而且發生內部嚴重伺服器錯誤 (記憶體不足的狀況、嚴重的寫入存取違規或傾印過多) 時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnModerateServerError:滿足任何狀況的較低值,而且發生一般伺服器錯誤 (持續的記憶體不足狀況) 時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnAnyQualifiedFailureConditions:滿足任何狀況的較低值,而且發生限定失敗狀況 (引擎工作者執行緒已耗盡、偵測到無法解決的死結) 時,便容錯移轉或重新啟動。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityGroupFailureConditionLevel</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>HealthCheckTimeout</maml:name><maml:description><maml:para>將沒有回應的伺服器宣告為狀況不良之前經過的時間長度 (以毫秒為單位)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AutomatedBackupPreference</maml:name><maml:description><maml:para>可用性群組的自動備份喜好設定。有效的選項包括: </maml:para><maml:para>Primary:指定備份一定要在主要複本上進行,不論其所在位置為何。這通常是因為使用者需要在次要複本上執行備份時無法使用的功能,例如差異備份。 </maml:para><maml:para>SecondaryOnly:指定絕對不能在主要複本上執行備份。如果主要複本是唯一的線上複本,就不會進行備份。 </maml:para><maml:para>Secondary:指定除非主要複本是唯一的線上複本,否則備份會在次要複本上進行。然後,備份會在主要複本上進行。 </maml:para><maml:para>None:此選項會指定您在選擇要執行備份的複本時,不想要將主要/次要狀態納入考量。只考慮 BackupPriority 以及上線/已連接狀態等因素。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityGroupAutomatedBackupPreference</command:parameterValue><dev:type><maml:name>AvailabilityGroupAutomatedBackupPreference</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailureConditionLevel</maml:name><maml:description><maml:para>決定可用性群組的自動容錯移轉行為。有效的選項包括: </maml:para><maml:para>OnServerDown:SQL Server 服務停止時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnServerUnresponsive:滿足任何狀況的較低值,而且 SQL Server 服務連接到叢集且超過 "HealthCheckTimeout" 臨界值,或者目前位於主要角色中的可用性複本處於失敗狀態時,便容錯移轉或重新啟動 (請參閱 HealthCheckTimeout 參數)。 </maml:para><maml:para>OnCriticalServerError:滿足任何狀況的較低值,而且發生內部嚴重伺服器錯誤 (記憶體不足的狀況、嚴重的寫入存取違規或傾印過多) 時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnModerateServerError:滿足任何狀況的較低值,而且發生一般伺服器錯誤 (持續的記憶體不足狀況) 時,便容錯移轉或重新啟動。 </maml:para><maml:para>OnAnyQualifiedFailureConditions:滿足任何狀況的較低值,而且發生限定失敗狀況 (引擎工作者執行緒已耗盡、偵測到無法解決的死結) 時,便容錯移轉或重新啟動。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityGroupFailureConditionLevel</command:parameterValue><dev:type><maml:name>AvailabilityGroupFailureConditionLevel</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>HealthCheckTimeout</maml:name><maml:description><maml:para>將沒有回應的伺服器宣告為狀況不良之前經過的時間長度 (以毫秒為單位)。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>要修改之可用性群組的 AvailabilityGroup 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">T</command:parameterValue><dev:type><maml:name>T</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-SqlAvailabilityGroup -Path SQLSERVER:\Sql\PrimaryServer\InstanceName\AvailabilityGroups\MyAG -HealthCheckTimeout 120000 </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將可用性群組 'MyAg' 的 HealhCheckTimeout 屬性設定為 120,000 毫秒 (兩分鐘)。如果主要伺服器在這段時間內沒有回應,而且自動容錯移轉已啟用,系統就會起始自動容錯移轉。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-SqlAvailabilityGroup -Path SQLSERVER:\Sql\PrimaryServer\InstanceName\AvailabilityGroups\MyAg -AutomatedBackupPreference SecondaryOnly </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將可用性群組 'MyAg' 的 AutomatedBackupPreference 屬性設定為 'SecondaryOnly'。這個可用性群組中資料庫的自動備份永遠不會在主要複本上進行,但是會重新導向至備份優先權最高的次要複本 (請參閱可用性複本的 BackupPriority 屬性)。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-SqlAvailabilityGroup -Path SQLSERVER:\Sql\PrimaryServer\InstanceName\AvailabilityGroups\MyAg -FailureConditionLevel OnServerDown </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將可用性群組 'MyAg' 的 FailureConditionLevel 屬性設定為 'OnServerDown'。這表示,當裝載主要複本的伺服器執行個體離線,而且自動容錯移轉已啟用時,系統就會起始自動容錯移轉。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Set-SqlAvailabilityGroupListener</command:name><maml:description><maml:para>這個 Cmdlet 會修改現有可用性群組接聽程式的通訊埠設定。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Set</command:verb><command:noun>SqlAvailabilityGroupListener</command:noun><dev:version /></command:details><maml:description><maml:para>Set-SqlAvailabilityGroupListener Cmdlet 會修改現有可用性群組接聽程式的通訊埠設定。這個 Cmdlet 只能在裝載主要複本的伺服器執行個體上執行。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Set-SqlAvailabilityGroupListener</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組接聽程式的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>接聽程式將用來接聽連接的 TCP 通訊埠。預設通訊埠是 TCP 通訊埠 1433。如果您有安全性考量,我們建議您使用不同的通訊埠編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Set-SqlAvailabilityGroupListener</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>要修改之接聽程式的 SMO AvailabilityGroupListener 物件。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>接聽程式將用來接聽連接的 TCP 通訊埠。預設通訊埠是 TCP 通訊埠 1433。如果您有安全性考量,我們建議您使用不同的通訊埠編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>要修改之接聽程式的 SMO AvailabilityGroupListener 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">T</command:parameterValue><dev:type><maml:name>T</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性群組接聽程式的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>接聽程式將用來接聽連接的 TCP 通訊埠。預設通訊埠是 TCP 通訊埠 1433。如果您有安全性考量,我們建議您使用不同的通訊埠編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue>1433</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.AvailabilityGroupListener</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-SqlAvailabilityGroupListener -Port 1535 -Path SQLSERVER:\Sql\PrimaryServer\InstanceName\AvailabilityGroups\MyAg\AvailabilityGroupListeners\MyListener </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將名為 'MyListener' 之可用性群組接聽程式的通訊埠編號設定為 1535。這個通訊埠是用來接聽接聽程式的連接。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-SqlAvailabilityGroupListener -Port 1535 -Script -Path SQLSERVER:\Sql\PrimaryServer\InstanceName\AvailabilityGroups\MyAg\AvailabilityGroupListeners\MyListener </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會產生 Transact-SQL 指令碼,這個指令碼會將名為 'MyListener' 之可用性群組接聽程式的通訊埠編號設定為 1535。此命令實際上不會變更通訊埠編號。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Set-SqlAvailabilityReplica</command:name><maml:description><maml:para>這個 Cmdlet 會修改現有可用性複本的設定。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Set</command:verb><command:noun>SqlAvailabilityReplica</command:noun><dev:version /></command:details><maml:description><maml:para>Set-SqlAvailabilityReplica Cmdlet 會設定或修改可用性複本的各種屬性。這個 Cmdlet 只能在裝載主要複本的伺服器執行個體上執行。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Set-SqlAvailabilityReplica</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性複本的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AvailabilityMode</maml:name><maml:description><maml:para>複本的可用性模式。選項包括:SynchronousCommit 或 AsynchronousCommit。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaAvailabilityMode</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupPriority</maml:name><maml:description><maml:para>此選項是 0..100 範圍內的整數,而且表示執行備份之複本的所需優先權。系統會從在線上而且可用的複本集中選擇優先權最高的複本來執行備份。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInPrimaryRole</maml:name><maml:description><maml:para>主要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowReadWriteConnections:允取讀取/寫入連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInPrimaryRole</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInSecondaryRole</maml:name><maml:description><maml:para>次要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowNoConnections:不允許連接 </maml:para><maml:para>AllowReadIntentConnectionsOnly:只允許讀取意圖的連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInSecondaryRole</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EndpointUrl</maml:name><maml:description><maml:para>採用 TCP://System-address:port 格式的端點 URL。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailoverMode</maml:name><maml:description><maml:para>複本的容錯移轉模式。選項包括:Manual 或 Automatic。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaFailoverMode</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadonlyRoutingConnectionUrl</maml:name><maml:description><maml:para>路由至複本進行唯讀連接時要使用的連接完整網域名稱 (FQDN) 和通訊埠。例如: </maml:para><maml:para>TCP://DBSERVER8.manufacturing.Adventure-Works.com:7024 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadOnlyRoutingList</maml:name><maml:description><maml:para>複本伺服器名稱的排序清單,這些名稱表示透過此可用性複本重新導向唯讀連接時供連接導向器使用的探查順序。這適用於可用性複本為可用性群組之目前主要複本的情況。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SessionTimeout</maml:name><maml:description><maml:para>將連接視為失敗之前,在主要複本與這個複本之間等候回應的秒數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Set-SqlAvailabilityReplica</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>要修改之複本的 AvailabilityReplica 物件。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AvailabilityMode</maml:name><maml:description><maml:para>複本的可用性模式。選項包括:SynchronousCommit 或 AsynchronousCommit。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaAvailabilityMode</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupPriority</maml:name><maml:description><maml:para>此選項是 0..100 範圍內的整數,而且表示執行備份之複本的所需優先權。系統會從在線上而且可用的複本集中選擇優先權最高的複本來執行備份。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInPrimaryRole</maml:name><maml:description><maml:para>主要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowReadWriteConnections:允取讀取/寫入連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInPrimaryRole</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInSecondaryRole</maml:name><maml:description><maml:para>次要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowNoConnections:不允許連接 </maml:para><maml:para>AllowReadIntentConnectionsOnly:只允許讀取意圖的連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInSecondaryRole</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EndpointUrl</maml:name><maml:description><maml:para>採用 TCP://System-address:port 格式的端點 URL。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailoverMode</maml:name><maml:description><maml:para>複本的容錯移轉模式。選項包括:Manual 或 Automatic。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaFailoverMode</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadonlyRoutingConnectionUrl</maml:name><maml:description><maml:para>路由至複本進行唯讀連接時要使用的連接完整網域名稱 (FQDN) 和通訊埠。例如: </maml:para><maml:para>TCP://DBSERVER8.manufacturing.Adventure-Works.com:7024 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadOnlyRoutingList</maml:name><maml:description><maml:para>複本伺服器名稱的排序清單,這些名稱表示透過此可用性複本重新導向唯讀連接時供連接導向器使用的探查順序。這適用於可用性複本為可用性群組之目前主要複本的情況。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SessionTimeout</maml:name><maml:description><maml:para>將連接視為失敗之前,在主要複本與這個複本之間等候回應的秒數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AvailabilityMode</maml:name><maml:description><maml:para>複本的可用性模式。選項包括:SynchronousCommit 或 AsynchronousCommit。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaAvailabilityMode</command:parameterValue><dev:type><maml:name>AvailabilityReplicaAvailabilityMode</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupPriority</maml:name><maml:description><maml:para>此選項是 0..100 範圍內的整數,而且表示執行備份之複本的所需優先權。系統會從在線上而且可用的複本集中選擇優先權最高的複本來執行備份。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInPrimaryRole</maml:name><maml:description><maml:para>主要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowReadWriteConnections:允取讀取/寫入連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInPrimaryRole</command:parameterValue><dev:type><maml:name>AvailabilityReplicaConnectionModeInPrimaryRole</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ConnectionModeInSecondaryRole</maml:name><maml:description><maml:para>次要角色中的可用性複本應該如何處理連接。有效的設定包括: </maml:para><maml:para>AllowNoConnections:不允許連接 </maml:para><maml:para>AllowReadIntentConnectionsOnly:只允許讀取意圖的連接 </maml:para><maml:para>AllowAllConnections:允許所有連接 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaConnectionModeInSecondaryRole</command:parameterValue><dev:type><maml:name>AvailabilityReplicaConnectionModeInSecondaryRole</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EndpointUrl</maml:name><maml:description><maml:para>採用 TCP://System-address:port 格式的端點 URL。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>FailoverMode</maml:name><maml:description><maml:para>複本的容錯移轉模式。選項包括:Manual 或 Automatic。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">AvailabilityReplicaFailoverMode</command:parameterValue><dev:type><maml:name>AvailabilityReplicaFailoverMode</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>要修改之複本的 AvailabilityReplica 物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">T</command:parameterValue><dev:type><maml:name>T</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>可用性複本的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadonlyRoutingConnectionUrl</maml:name><maml:description><maml:para>路由至複本進行唯讀連接時要使用的連接完整網域名稱 (FQDN) 和通訊埠。例如: </maml:para><maml:para>TCP://DBSERVER8.manufacturing.Adventure-Works.com:7024 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ReadOnlyRoutingList</maml:name><maml:description><maml:para>複本伺服器名稱的排序清單,這些名稱表示透過此可用性複本重新導向唯讀連接時供連接導向器使用的探查順序。這適用於可用性複本為可用性群組之目前主要複本的情況。 </maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SessionTimeout</maml:name><maml:description><maml:para>將連接視為失敗之前,在主要複本與這個複本之間等候回應的秒數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>Microsoft.SqlServer.Management.Smo.AvailabilityReplica</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 要修改的可用性複本。 </maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-SqlAvailabilityReplica -AvailabilityMode "SynchronousCommit" -FailoverMode "Automatic" -Path SQLSERVER:\Sql\PrimaryServer\InstanceName\AvailabilityGroups\MyAg\AvailabilityReplicas\MyReplica </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將可用性群組 'MyAg' 中的複本 'MyReplica' 修改成使用同步認可的可用性模式並且支援自動容錯移轉。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-SqlAvailabilityReplica -AvailabilityMode "AsynchronousCommit" -FailoverMode "Manual" -Path SQLSERVER:\Sql\PrimaryServer\InstanceName\AvailabilityGroups\MyAg\AvailabilityReplicas\MyReplica </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將可用性群組 'MyAg' 中的複本 'MyReplica' 修改成使用非同步認可的可用性模式並且僅支援強制手動容錯移轉 (可能會遺失資料)。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-SqlAvailabilityReplica -ConnectionModeInSecondaryRole "AllowAllConnections" -Path SQLSERVER:\Sql\PrimaryServer\InstanceName\AvailabilityGroups\MyAg\AvailabilityReplicas\MyReplica </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將可用性群組 'MyAg' 中的複本 'MyReplica' 修改成允許次要角色的所有連接。如果您想要將唯讀資料處理工作負載卸載至次要複本,這就很有用。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 4 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-Location SQLSERVER:\SQL\PrimaryServer\default\AvailabilityGroups\MyAg $primaryReplica = Get-Item "AvailabilityReplicas\PrimaryServer" $secondaryReplica = Get-Item "AvailabilityReplicas\SecondaryServer" Set-SqlAvailabilityReplica -ReadOnlyRoutingConnectionUrl "TCP://PrimaryServer.domain.com:5022" -InputObject $primaryReplica Set-SqlAvailabilityReplica -ReadOnlyRoutingConnectionUrl "TCP://SecondaryServer.domain.com:5022" -InputObject $secondaryReplica Set-SqlAvailabilityReplica -ReadOnlyRoutingList "SecondaryServer","PrimaryServer" -InputObject $primaryReplica </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會將可用性群組中的主要複本和一個次要複本設定為唯讀路由。如果 ConnectionModeInSecondaryRole 選項設定為 AllowAllConnections 或 AllowReadIntentConnectionsOnly,唯讀路由可讓次要複本在用戶端透過虛擬網路名稱連接到可用性群組時接收並接受讀取要求。首先,此範例會將唯讀路由 URL 指派給每個複本。然後,它會設定主要複本的唯讀路由清單。在連接字串中設定 "ReadOnly" 屬性的連接將會重新導向至次要複本。如果這個次要複本無法讀取 (由 ConnectionModeInSecondaryRole 設定決定),連接將會導向回到主要複本。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 5 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-SqlAvailabilityReplica -BackupPriority 60 -Path SQLSERVER:\Sql\Computer\Instance\AvailabilityGroups\MyAg\AvailabilityReplicas\MyReplica </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將可用性複本 'MyReplica' 的備份優先權設定為 60。裝載主要複本的伺服器執行個體會使用這個優先權來決定哪個複本應該服務可用性群組中資料庫的自動備份要求 (系統會選擇優先權最高的複本)。這個優先權可以是 0 和 100 (含) 之間的任何數字。如果優先權為 0,就表示系統不應該將複本視為服務備份要求的候選。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Set-SqlCredential</command:name><maml:description><maml:para>設定 SQL Credential 物件的屬性</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Set</command:verb><command:noun>SqlCredential</command:noun><dev:version /></command:details><maml:description><maml:para>您可以使用這個 Cmdlet,設定 SQL Credential 物件的 Identity 和 password 屬性。這個 Cmdlet 支援下列兩種作業模式: 1.藉由使用 –path 參數指定內含認證名稱的認證路徑或位置。 2.藉由使用 –InputObject 將 Smo.Credential 物件傳遞給物件。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Set-SqlCredential</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行此作業之 Credential 的路徑。例如:SQLSERVER:\SQL\Computer\Instance\Credentials\Credential </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Identity</maml:name><maml:description><maml:para>指定必須驗證之資源 SQL Server 的使用者或帳戶名稱。如果是 Windows Azure 儲存體服務,這個參數就是 Windows Azure 儲存體帳戶的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="4" aliases=""><maml:name>Secret</maml:name><maml:description><maml:para>請使用這個參數指定使用者或帳戶的密碼。如果是 Windows Azure 儲存體服務,這個參數就是 Windows Azure 儲存體帳戶的存取金鑰值。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">SecureString</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Set-SqlCredential</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>輸入認證物件。您可以使用 Get-SqlCredential Cmdlet 取得這個物件。 </maml:para></maml:description></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Identity</maml:name><maml:description><maml:para>指定必須驗證之資源 SQL Server 的使用者或帳戶名稱。如果是 Windows Azure 儲存體服務,這個參數就是 Windows Azure 儲存體帳戶的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="4" aliases=""><maml:name>Secret</maml:name><maml:description><maml:para>請使用這個參數指定使用者或帳戶的密碼。如果是 Windows Azure 儲存體服務,這個參數就是 Windows Azure 儲存體帳戶的存取金鑰值。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">SecureString</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Identity</maml:name><maml:description><maml:para>指定必須驗證之資源 SQL Server 的使用者或帳戶名稱。如果是 Windows Azure 儲存體服務,這個參數就是 Windows Azure 儲存體帳戶的名稱。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>輸入認證物件。您可以使用 Get-SqlCredential Cmdlet 取得這個物件。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">T</command:parameterValue><dev:type><maml:name>T</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行此作業之 Credential 的路徑。例如:SQLSERVER:\SQL\Computer\Instance\Credentials\Credential </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="4" aliases=""><maml:name>Secret</maml:name><maml:description><maml:para>請使用這個參數指定使用者或帳戶的密碼。如果是 Windows Azure 儲存體服務,這個參數就是 Windows Azure 儲存體帳戶的存取金鑰值。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">SecureString</command:parameterValue><dev:type><maml:name>SecureString</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>Set-SqlCredential -Path SQLSERVER:\SQL\Computer\Instance\Credentials\MySqlCredential –Identity "mystorageaccount" </dev:code><dev:remarks><maml:para>此命令會藉由指定 SQL Credential 的路徑,將 MySqlCredential 的識別設定為 'mystorageaccount'。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>The command retrieves the credential object from the Get-Credential cmdlet and then pipes it to the Set-Sql Credential cmdlet to set the identity of mySqLCrendential to ‘mystorageaccount’. PS C:\> $cred = Get-SqlCredential -Name MySqlCredential $cred | Set-SqlCredential –Identity "mystorageaccount" </dev:code><dev:remarks></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 3-------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>The command prompts for the storage access key information and the Set-Sql Credential cmdlet to set the value for SECRET with the input value. PS C:\> $secret = read-host "Please enter the storage account access key" PS C:\> Set-SqlCredential –Identity "mystorageaccount" –Secret $secret </dev:code><dev:remarks></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Set-SqlHADREndpoint</command:name><maml:description><maml:para>設定現有資料庫鏡像端點的屬性。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Set</command:verb><command:noun>SqlHADREndpoint</command:noun><dev:version /></command:details><maml:description><maml:para>Set-SqlHadrEndpoint Cmdlet 可讓您變更現有資料庫鏡像端點的屬性 (名稱、狀態、驗證屬性等等)。 </maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Set-SqlHADREndpoint</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>資料庫鏡像端點的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AuthenticationOrder</maml:name><maml:description><maml:para>端點所使用的驗證順序和類型。選項包括 Certificate、CertificateKerberos、CertificateNegotiate、CertificateNtlm、Kerberos、KerberosCertificate、Negotiate、NegotiateCertificate、Ntlm 和 NtlmCertificate。如果指定的選項需要憑證,除非憑證已經與端點產生關聯,否則您也必須設定 -Certificate 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointAuthenticationOrder</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Certificate</maml:name><maml:description><maml:para>端點應該用來驗證連接的憑證名稱。遠端點必須有一個特定憑證,該憑證含有符合指定憑證之私密金鑰的公開金鑰。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Encryption</maml:name><maml:description><maml:para>端點加密設定。選項包括 Disabled、Supported 或 Required。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointEncryption</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionAlgorithm</maml:name><maml:description><maml:para>端點所使用的加密格式。選項包括 Aes、AesRC4、None、RC4 和 RC4Aes。 </maml:para><maml:para>注意:只有 RC4 演算法支援回溯相容性。只有在資料庫相容性層級為 90 或 100 時,才能使用 RC4 或 RC4_128 加密新資料 (不建議使用)。請改用較新的演算法,例如其中一個 AES 演算法。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointEncryptionAlgorithm</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>IpAddress</maml:name><maml:description><maml:para>端點將接聽的 IP 位址。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">IPAddress</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Owner</maml:name><maml:description><maml:para>端點的擁有者。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>端點用來接聽連接的 TCP 通訊埠編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>State</maml:name><maml:description><maml:para>端點的狀態:Started、Stopped 或 Disabled。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointState</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Set-SqlHADREndpoint</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該修改之端點的 Endpoint 物件。這個物件必須是資料庫鏡像端點。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AuthenticationOrder</maml:name><maml:description><maml:para>端點所使用的驗證順序和類型。選項包括 Certificate、CertificateKerberos、CertificateNegotiate、CertificateNtlm、Kerberos、KerberosCertificate、Negotiate、NegotiateCertificate、Ntlm 和 NtlmCertificate。如果指定的選項需要憑證,除非憑證已經與端點產生關聯,否則您也必須設定 -Certificate 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointAuthenticationOrder</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Certificate</maml:name><maml:description><maml:para>端點應該用來驗證連接的憑證名稱。遠端點必須有一個特定憑證,該憑證含有符合指定憑證之私密金鑰的公開金鑰。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Encryption</maml:name><maml:description><maml:para>端點加密設定。選項包括 Disabled、Supported 或 Required。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointEncryption</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionAlgorithm</maml:name><maml:description><maml:para>端點所使用的加密格式。選項包括 Aes、AesRC4、None、RC4 和 RC4Aes。 </maml:para><maml:para>注意:只有 RC4 演算法支援回溯相容性。只有在資料庫相容性層級為 90 或 100 時,才能使用 RC4 或 RC4_128 加密新資料 (不建議使用)。請改用較新的演算法,例如其中一個 AES 演算法。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointEncryptionAlgorithm</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>IpAddress</maml:name><maml:description><maml:para>端點將接聽的 IP 位址。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">IPAddress</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Owner</maml:name><maml:description><maml:para>端點的擁有者。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>端點用來接聽連接的 TCP 通訊埠編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>State</maml:name><maml:description><maml:para>端點的狀態:Started、Stopped 或 Disabled。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointState</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AuthenticationOrder</maml:name><maml:description><maml:para>端點所使用的驗證順序和類型。選項包括 Certificate、CertificateKerberos、CertificateNegotiate、CertificateNtlm、Kerberos、KerberosCertificate、Negotiate、NegotiateCertificate、Ntlm 和 NtlmCertificate。如果指定的選項需要憑證,除非憑證已經與端點產生關聯,否則您也必須設定 -Certificate 參數。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointAuthenticationOrder</command:parameterValue><dev:type><maml:name>EndpointAuthenticationOrder</maml:name><maml:uri /></dev:type><dev:defaultValue>SMO.EndpointAuthenticationOrder.Negotiate</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Certificate</maml:name><maml:description><maml:para>端點應該用來驗證連接的憑證名稱。遠端點必須有一個特定憑證,該憑證含有符合指定憑證之私密金鑰的公開金鑰。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Encryption</maml:name><maml:description><maml:para>端點加密設定。選項包括 Disabled、Supported 或 Required。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointEncryption</command:parameterValue><dev:type><maml:name>EndpointEncryption</maml:name><maml:uri /></dev:type><dev:defaultValue>SMO.EndpointAuthentication.Required</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionAlgorithm</maml:name><maml:description><maml:para>端點所使用的加密格式。選項包括 Aes、AesRC4、None、RC4 和 RC4Aes。 </maml:para><maml:para>注意:只有 RC4 演算法支援回溯相容性。只有在資料庫相容性層級為 90 或 100 時,才能使用 RC4 或 RC4_128 加密新資料 (不建議使用)。請改用較新的演算法,例如其中一個 AES 演算法。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointEncryptionAlgorithm</command:parameterValue><dev:type><maml:name>EndpointEncryptionAlgorithm</maml:name><maml:uri /></dev:type><dev:defaultValue>RC4</dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>應該修改之端點的 Endpoint 物件。這個物件必須是資料庫鏡像端點。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">T</command:parameterValue><dev:type><maml:name>T</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>IpAddress</maml:name><maml:description><maml:para>端點將接聽的 IP 位址。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">IPAddress</command:parameterValue><dev:type><maml:name>IPAddress</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Owner</maml:name><maml:description><maml:para>端點的擁有者。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>資料庫鏡像端點的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>端點用來接聽連接的 TCP 通訊埠編號。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue>4022</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。 </maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>State</maml:name><maml:description><maml:para>端點的狀態:Started、Stopped 或 Disabled。 </maml:para></maml:description><command:parameterValue required="true" variableLength="false">EndpointState</command:parameterValue><dev:type><maml:name>EndpointState</maml:name><maml:uri /></dev:type><dev:defaultValue>SMO.EndpointState.Stopped</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name>SMO.Endpoint</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para> 要設定其屬性的 AlwaysOn 端點。 </maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name>SMO.Endpoint</maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-SqlHadrEndpoint -Path SQLSERVER:\Sql\Computer\Instance\Endpoints\MyDbmEndpoint -Port 5050 </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會將伺服器執行個體 'Computer\Instance' 上名為 'MyDbmEndpoint' 之資料庫鏡像端點的通訊埠編號設定為 5050。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\PS>Set-SqlHadrEndpoint -Path SQLSERVER:\Sql\Computer\Instance\Endpoints\MyDbmEndpoint -State Started </dev:code><dev:remarks><maml:para>說明 </maml:para><maml:para>----------- </maml:para><maml:para>此命令會啟動伺服器執行個體 'Computer\Instance' 上名為 'MyDbmEndpoint' 的資料庫鏡像端點。 </maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText></maml:linkText><maml:uri /></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Set-SqlNetworkConfiguration</command:name><maml:description><maml:para>設定目標 SQL Server 執行個體的網路組態。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Set</command:verb><command:noun>SqlNetworkConfiguration</command:noun><dev:version /></command:details><maml:description><maml:para>設定目標 SQL Server 執行個體的網路組態。</maml:para><maml:para>SQL Server 雲端配接器必須在主控 SQL Server 執行個體的電腦上執行及存取。</maml:para><maml:para>這個 Cmdlet 支援下列作業模式:</maml:para><maml:para>1.透過指定執行個體 PowerShell 路徑。</maml:para><maml:para>2.透過指定伺服器物件。</maml:para><maml:para>3.透過指定目標 SQL Server 執行個體的 ServerInstance。</maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Set-SqlNetworkConfiguration</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Protocol</maml:name><maml:description><maml:para>指定想在目標 SQL Server 執行個體上設定的網路通訊協定。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Protocols</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>接受 TCP 連線的連接埠。若要設定動態連接埠,此參數應設為零。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Disable</maml:name><maml:description><maml:para>指定想在目標 SQL Server 執行個體上停用的指定網路通訊協定。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ForceServiceRestart</maml:name><maml:description><maml:para>必要時,強制重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>避免重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Set-SqlNetworkConfiguration</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Protocol</maml:name><maml:description><maml:para>指定想在目標 SQL Server 執行個體上設定的網路通訊協定。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Protocols</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>接受 TCP 連線的連接埠。若要設定動態連接埠,此參數應設為零。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Disable</maml:name><maml:description><maml:para>指定想在目標 SQL Server 執行個體上停用的指定網路通訊協定。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ForceServiceRestart</maml:name><maml:description><maml:para>必要時,強制重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>避免重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>目標執行個體的伺服器物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">Server[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Set-SqlNetworkConfiguration</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Protocol</maml:name><maml:description><maml:para>指定想在目標 SQL Server 執行個體上設定的網路通訊協定。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Protocols</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>接受 TCP 連線的連接埠。若要設定動態連接埠,此參數應設為零。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Disable</maml:name><maml:description><maml:para>指定想在目標 SQL Server 執行個體上停用的指定網路通訊協定。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ForceServiceRestart</maml:name><maml:description><maml:para>必要時,強制重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>避免重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>此參數可指定將成為作業目標之 SQL Server 執行個體的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>AcceptSelfSignedCertificate</maml:name><maml:description><maml:para>強制 Cmdlet 自動接受目標電腦的 SQL Server 雲端配接器自我簽署憑證,而不提示使用者。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="1" aliases=""><maml:name>Credential</maml:name><maml:description><maml:para>在目標電腦上指定具有 Windows 管理員認證的使用者帳戶。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSCredential</command:parameterValue><dev:type><maml:name>PSCredential</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Disable</maml:name><maml:description><maml:para>指定想在目標 SQL Server 執行個體上停用的指定網路通訊協定。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ForceServiceRestart</maml:name><maml:description><maml:para>必要時,強制重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue)" position="named" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>目標執行個體的伺服器物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">Server[]</command:parameterValue><dev:type><maml:name>Server[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>ManagementPublicPort</maml:name><maml:description><maml:para>目標電腦上的公用管理連接埠。當您無法直接存取目標電腦的連接埠,但該連接埠有透過端點公開時,即應使用此參數,表示我們必須連線到其他連接埠。</maml:para><maml:para>SQL Server 雲端配接器必須以此連接埠存取。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>NoServiceRestart</maml:name><maml:description><maml:para>避免重新啟動 SQL Server 服務,而不提示使用者。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>您想要執行作業之 SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值預設為目前的工作位置。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="3" aliases=""><maml:name>Port</maml:name><maml:description><maml:para>接受 TCP 連線的連接埠。若要設定動態連接埠,此參數應設為零。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Protocol</maml:name><maml:description><maml:para>指定想在目標 SQL Server 執行個體上設定的網路通訊協定。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Protocols</command:parameterValue><dev:type><maml:name>Protocols</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>RetryTimeout</maml:name><maml:description><maml:para>在目標伺服器上重試命令的時間週期。超過逾時設定之後,就不會再嘗試重試。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByValue, ByPropertyName)" position="named" aliases=""><maml:name>ServerInstance</maml:name><maml:description><maml:para>此參數可指定將成為作業目標之 SQL Server 執行個體的名稱。</maml:para></maml:description><command:parameterValue required="true" variableLength="true">String[]</command:parameterValue><dev:type><maml:name>String[]</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>PS C:\>CD SQLSERVER:\SQL\Computer\Instance; Set-SqlNetworkConfiguration -Credential $credential -Protocol TCP -Port 1433 -NoServiceRestart -AcceptSelfSignedCertificate; </dev:code><dev:remarks><maml:para>此命令會將伺服器執行個體 'Computer\Instance' 的網路組態,設定為接受連接埠 1433 的 TCP 連線。目前的工作目錄會用來決定應該進行作業的伺服器執行個體。SQL Server 服務將不會自動重新啟動。系統會自動接受目標電腦的自我簽署憑證,而不提示使用者。</maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title></maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>This command retrieves all instances of SQL Server on the machine ‘MachineName’ and disables TCP connections for each one of them. The SQL Server service will not be restarted automatically. The self-signed certificate of the target machine will be automatically accepted without prompting the user. PS C:\>Get-SqlInstance -Credential $credential -MachineName "MachineName" | Set-SqlNetworkConfiguration -Credential $credential -Protocol TCP -Disable -NoServiceRestart -AcceptSelfSignedCertificate; </dev:code><dev:remarks><maml:para></maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example></command:examples><maml:relatedLinks><maml:navigationLink><maml:linkText>Online Version:</maml:linkText><maml:uri></maml:uri></maml:navigationLink></maml:relatedLinks></command:command><command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"><command:details><command:name>Set-SqlSmartAdmin</command:name><maml:description><maml:para>此 Cmdlet 可設定或修改備份保留及儲存設定。</maml:para></maml:description><maml:copyright><maml:para /></maml:copyright><command:verb>Set</command:verb><command:noun>SqlSmartAdmin</command:noun><dev:version /></command:details><maml:description><maml:para>Set-SqlSmartAdmin Cmdlet 可設定或修改 BackupEnabled、BackupRetentionPeriodinDays、MasterSwitch 及 SqlCredential 參數設定。僅可針對執行個體層級的組態來執行 Cmdlet,而不能針對特定資料庫。</maml:para><maml:para>這個 Cmdlet 支援下列傳回物件的作業模式: 1.將 Smo.Server 物件傳遞給 -InputObject 參數 (直接或透過管線)。 2.傳遞 SQL Server 執行個體到 -Path 參數的路徑</maml:para></maml:description><command:syntax><command:syntaxItem><maml:name>Set-SqlSmartAdmin</maml:name><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值會使用目前的工作目錄。當您建立指令碼以管理多個執行個體時,這會非常有用。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupEnabled</maml:name><maml:description><maml:para>用來啟用或停用 SQL Server Managed Backup 到 Windows Azure 的參數。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Boolean</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupRetentionPeriodInDays</maml:name><maml:description><maml:para>備份檔案應保留的天數。此天數可決定資料庫復原能力的時間範圍。例如,若您的設定值為 30 天,即可將資料庫復原至最近 30 天的時間點。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionOption</maml:name><maml:description><maml:para>加密選項。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptionOptions</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MasterSwitch</maml:name><maml:description><maml:para>用來暫停或重新啟動 Smart Admin 底下的所有服務 (包括 SQL Server Managed Backup 到 Windows Azure)。這是必要參數。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Boolean</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>用來驗證 Windows Azure 儲存體帳戶的 SqlCredential 物件。這是必要參數。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem><command:syntaxItem><maml:name>Set-SqlSmartAdmin</maml:name><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>Smo Smart Admin 物件。可使用 Get-SqlSmartAdmin Cmdlet 擷取這個物件。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupEnabled</maml:name><maml:description><maml:para>用來啟用或停用 SQL Server Managed Backup 到 Windows Azure 的參數。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Boolean</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupRetentionPeriodInDays</maml:name><maml:description><maml:para>備份檔案應保留的天數。此天數可決定資料庫復原能力的時間範圍。例如,若您的設定值為 30 天,即可將資料庫復原至最近 30 天的時間點。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionOption</maml:name><maml:description><maml:para>加密選項。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptionOptions</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MasterSwitch</maml:name><maml:description><maml:para>用來暫停或重新啟動 Smart Admin 底下的所有服務 (包括 SQL Server Managed Backup 到 Windows Azure)。這是必要參數。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Boolean</command:parameterValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>用來驗證 Windows Azure 儲存體帳戶的 SqlCredential 物件。這是必要參數。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description></command:parameter></command:syntaxItem></command:syntax><command:parameters><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupEnabled</maml:name><maml:description><maml:para>用來啟用或停用 SQL Server Managed Backup 到 Windows Azure 的參數。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Boolean</command:parameterValue><dev:type><maml:name>Boolean</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>BackupRetentionPeriodInDays</maml:name><maml:description><maml:para>備份檔案應保留的天數。此天數可決定資料庫復原能力的時間範圍。例如,若您的設定值為 30 天,即可將資料庫復原至最近 30 天的時間點。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Int32</command:parameterValue><dev:type><maml:name>Int32</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>EncryptionOption</maml:name><maml:description><maml:para>加密選項。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">BackupEncryptionOptions</command:parameterValue><dev:type><maml:name>BackupEncryptionOptions</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="true" variableLength="false" globbing="false" pipelineInput="True (ByValue)" position="2" aliases=""><maml:name>InputObject</maml:name><maml:description><maml:para>Smo Smart Admin 物件。可使用 Get-SqlSmartAdmin Cmdlet 擷取這個物件。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">T</command:parameterValue><dev:type><maml:name>T</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>MasterSwitch</maml:name><maml:description><maml:para>用來暫停或重新啟動 Smart Admin 底下的所有服務 (包括 SQL Server Managed Backup 到 Windows Azure)。這是必要參數。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">Boolean</command:parameterValue><dev:type><maml:name>Boolean</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="2" aliases=""><maml:name>Path</maml:name><maml:description><maml:para>SQL Server 執行個體的路徑。這是選擇性參數。如果未指定,此參數的值會使用目前的工作目錄。當您建立指令碼以管理多個執行個體時,這會非常有用。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">String</command:parameterValue><dev:type><maml:name>String</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>Script</maml:name><maml:description><maml:para>輸出執行此 Cmdlet 所執行之工作的 Transact-SQL 指令碼。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="false" globbing="false" pipelineInput="false" position="named" aliases=""><maml:name>SqlCredential</maml:name><maml:description><maml:para>用來驗證 Windows Azure 儲存體帳戶的 SqlCredential 物件。這是必要參數。</maml:para></maml:description><command:parameterValue required="true" variableLength="false">PSObject</command:parameterValue><dev:type><maml:name>PSObject</maml:name><maml:uri /></dev:type><dev:defaultValue></dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>Confirm</maml:name><maml:description><maml:para>在執行 Cmdlet 之前提示您確認。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter><command:parameter required="false" variableLength="true" globbing="false" pipelineInput="false" position="named"><maml:name>WhatIf</maml:name><maml:description><maml:para>描述當您執行 Cmdlet 時沒有實際執行 Cmdlet 會發生什麼事。</maml:para></maml:description><command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue><dev:type><maml:name>SwitchParameter</maml:name><maml:uri /></dev:type><dev:defaultValue>false</dev:defaultValue></command:parameter></command:parameters><command:inputTypes><command:inputType><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:inputType></command:inputTypes><command:returnValues><command:returnValue><dev:type><maml:name></maml:name><maml:uri></maml:uri><maml:description><maml:para /></maml:description></dev:type><maml:description><maml:para></maml:para></maml:description></command:returnValue></command:returnValues><command:terminatingErrors /><command:nonTerminatingErrors /><command:examples><command:example><maml:title> -------------------------- EXAMPLE 1 -------------------------- </maml:title><maml:introduction><maml:para></maml:para></maml:introduction><dev:code>C:\ PS> cd SQLSERVER:\SQL\Computer\MyInstance </dev:code><dev:code>PS C:\>Get-SqlSmartAdmin | Set-SqlSmartAdmin –BackupEnabled $True –BackupRetentionPeriodInDays 10 </dev:code><dev:remarks><maml:para>描述 </maml:para><maml:para>----------- </maml:para><maml:para>此範例會設定 'MyInstance' 的雲端備份設定。其中會使用 Get-SqlSmartAdmin Cmdlet 擷取 Smart Admin 物件,並透過管線將其傳送給 Set-SqlSmartAdmin Cmdlet。</maml:para></dev:remarks><command:commandLines><command:commandLine><command:commandText /></command:commandLine></command:commandLines></command:example><command:example><maml:title> -------------------------- EXAMPLE 2 -------------------------- &nb |