關於Windows PowerShell的想法(二)

奇怪爲什麼在安裝SQL2008時會有這個工具,在聯機從書中看到了新特性之一後就明白了:

"

SQL Server PowerShell Provider and Cmdlets

SQL Server 2008 introduces two PowerShell snap-in dll files that implement the following:

  • A SQL Server PowerShell provider that exposes the SQL Server Management Object models as paths similar to file system paths. Each node in the path is associated with a SQL Server Management Object class.

  • A set of SQL Server PowerShell cmdlets for tasks such as running sqlcmd scripts or encoding delimited identifiers for use in PowerShell paths.

In addition, there is a new sqlps utility that launches a PowerShell environment configured with the SQL Server features such as the provider and snap-ins. A PowerShell subsystem has been added to SQL Server Agent so that you can run PowerShell scripts on a schedule or in response to 數據庫引擎 events. You can launch SQL Server PowerShell sessions by right-clicking Object Explorer nodes in SQL Server Management Studio. For more information, see <?xml:namespace prefix = mshelp />SQL Server PowerShell Overview."

打開相應的鏈接進入了介紹,這裏面的另一句話讓我更爲吃驚:

"SQL Server 2008 introduces support for Microsoft PowerShell. PowerShell is a powerful scripting shell that lets administrators and developers automate server administration and application deployment. The PowerShell language supports more complex logic than Transact-SQL scripts, giving SQL Server administrators the ability to build robust administration scripts. PowerShell scripts can also be used to administer other Microsoft server products. This gives administrators a common scripting language across servers."

看起來MS是想借.net平臺做一個類似於MMC的玩意兒,只不過這個是用來寫腳本進行管理,而MMC是圖形界面的,並且業界一直傳着:能用圖形界面的命令行方式就一定能完成,能用命令行完成的,圖形界面不一定能完成.MS看來是要增強命令行,而且還要和UNIX SHELL一樣,能做強大的腳本.

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章