發佈至遠端 WebSphere Application Server 時 Microsoft SQL Server JDBC 驅動程式的限制

當您使用 Microsoft SQL JDBC 驅動程式來發佈至遠端 WebSphere® Application Server 時,可能會收到下列錯誤,這是已知的問題。此錯誤會使您無法建立資料庫連線:

重要: 適用於 WebSphere Application Server 傳統版
SystemOut
     O [Microsoft][SQLServer 2000 Driver for JDBC]開啟/載入 com.microsoft.util.transliteration.properties 時發生錯誤。
SystemErr
     R java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]開啟/載入 com.microsoft.util.transliteration.properties 時發生錯誤。

若要暫時解決這個問題,請執行下列動作:

  1. 將下列 Microsoft SQL Server JAR 檔複製到 x:\AppServer\lib 資料夾(其中 x 是 WebSphere Application Server 的安裝目錄:
    • msbase.jar
    • mssqlserver.jar
    • msutil.jar
  2. 如果您想要將 JAR 檔放在其他位置,請執行下列動作:
    1. 在 WebSphere Application Server 安裝目錄中,開啟下列目錄。
      x:\profiles\properties
      其中 x:\profiles 是 WebSphere Application Server 設定檔的目錄。
    2. 編輯 server.policy 檔案,並將 JAR 檔的許可權變更為諸如讀取權等。
      // WebSphere system classes  
      grant codeBase "file:${was.install.root}/lib-" { 
          permission java.security.AllPermission;
      permission java.io.FilePermission
      "${was.install.root}${/}lib${/}msbase.jar", "read"; 
      permission java.io.FilePermission
      "${was.install.root}${/}lib${/}msutil.jar", "read"; 
      permission java.io.FilePermission
      "${was.install.root}${/}lib${/}mssqlserver.jar", "read"; 
      };
Icon that indicates the type of topic Reference topic
Timestamp icon Last updated: last_date

File name: rmssql.html