iT邦幫忙

0

SQL 指令

匿名 2008-11-02 23:32:379395 瀏覽

公司之存貨資料庫用MSDE database server,
請問怎樣用可更改sa 的password ? 是否要用sql 改?

另請問以下sql statement 的用途?

  1. exec sp_droplogin 'ublc'

  2. exec sp_addlogin 'ublc', 'ublc'

  3. exec sp_grantdbaccess 'ublc'

  4. exec sp_revokedbaccess 'ublc'

圖片
  直播研討會
圖片
{{ item.channelVendor }} {{ item.webinarstarted }} |
{{ formatDate(item.duration) }}
直播中

1 個回答

29
lancelotz
iT邦新手 3 級 ‧ 2008-11-03 09:19:17
最佳解答

開啟SQL Server Management Studio,「安全性」->「登入」->右邊的「SA」按右鍵,選屬性,就可以改了。

  1. sp_droplogin:移除 Microsoft SQL Server 登入,防止以該登入名稱存取 SQL Server 的執行個體。
  2. sp_addlogin:建立一項新的 SQL Server 登入,讓使用者利用 SQL Server 驗證來連接 SQL Server 的執行個體。
  3. sp_grantdbaccess:將資料庫使用者加入目前資料庫中。
  4. sp_revokedbaccess:從目前資料庫移除資料庫使用者。

請善用MSDN查詢。

lancelotz iT邦新手 3 級 ‧ 2008-11-03 09:24:45 檢舉

另外,想要用SQL指令改sa密碼,你可以查詢sp_password找看看相關資訊。

匿名 檢舉

AS MSDE comes with no GUI tools to administer it.
My Windows platform is XP Prof. How can I use Batch file (.bat) to execute the sql file to change the passowrd. I am sorry that I am not familiar with sql statement.

我要發表回答

立即登入回答