共用方式為


列出 Project Server 2003 資料庫設定檔

 

適用版本: Project Server 2010

上次修改主題的時間: 2010-06-10

執行 Microsoft Office Project Server 2003 設定檔指令碼 A2 可對打算移轉的資料庫擷取統計資料。此指令碼的輸出會提供下列資訊:

  • 資料庫大小 (專案資料表和網頁資料表資料庫)

  • 專案數目

  • 插入的專案數目

  • 跨專案連結數目

  • 任務數目

  • 工作分派數目

  • 企業資源數目

  • 使用中的自訂欄位數目

  • 經過 Project 驗證的使用者人數

  • 經過 Windows 驗證的使用者人數

  • 安全性群組數目

  • 安全性類別數目

  • 如果與 Windows SharePoint Services 整合

  • 連結的議題數目

  • 連結的風險數目

  • 連結的文件數目

  • 自訂 Project Web Access 檢視數目

您必須在指令碼的 USE 陳述式中,輸入「專案資料表」資料庫和「網頁資料表」資料庫的名稱。

Project Server 2003 設定檔指令碼 A2

/*-----------------------------------------------------------------------------------------------------------
Script A2: Project Server 2003 Database Profile
This script reads the Project Server 2003 database (Project Tables and View Tables may be in the same or separate database)
-------------------------------------------------------------------------------------------------------------*/
use <Enter "Project Tables" database name>

--Total size of DB 
exec sp_spaceused 

--Number of projects in the database
select count(*) as 'Total Number of Projects in 2003' from msp_projects

--Number of inserted projects
select count(*) as 'Number of Inserted Projects in 2003' 
  from MSP_TEXT_FIELDS where TEXT_FIELD_ID = 188743706

--Number of cross-project links
select count(*) as 'Number of cross-project links in 2003' 
  from MSP_TEXT_FIELDS 
  where TEXT_FIELD_ID = 239075346 or TEXT_FIELD_ID = 239075347

--Number of total tasks, assignments in the system
select count(*) as 'Number of tasks in 2003' from msp_tasks
select count(*) as 'Number of assignments in 2003' from msp_assignments

--Number of Enterprise resources (in ResGlobal)
select count(*) as 'Number of Enterprise Resources in 2003' 
  from msp_resources where proj_id = 1 and res_name is not null

--Number of custom fields in use
select count(*) as 'Number of Custom Fields in use in 2003' 
  from msp_field_attributes 
  where attrib_id = 206 and proj_id in (select proj_id 
  from msp_projects where proj_type =2 )

/*-----------------------------------------------------------------------------------------------------------
This script reads the Project Server 2003 database (Project Tables and View Tables may be in the same or separate database)
-------------------------------------------------------------------------------------------------------------*/

use <Enter "Web Tables" database name>

--Total size of DB 
exec sp_spaceused 

--Number of Project Authenticated users, Windows authenticated users
select count(*) as 'Number of Project Authenticated users in 2003'  
  from MSP_WEB_RESOURCES 
  where WRES_USE_NT_LOGON = 0 
  and WRES_CAN_LOGIN <>0 and WRES_COUNT_LICENSE <> 0
select count(*) as 'Number of Windows Authenticated users in 2003' 
  from MSP_WEB_RESOURCES 
  where WRES_USE_NT_LOGON <> 0 
  and WRES_CAN_LOGIN <>0 and WRES_COUNT_LICENSE <> 0

--Number of security groups,security categories
select count(*) as 'Number of Security Groups in 2003' 
  from MSP_WEB_SECURITY_GROUPS
select count(*) as 'Number of Security Categories in 2003' 
  from MSP_WEB_SECURITY_CATEGORIES

--Is there any Windows SharePoint Services integration ?
select count(*)  as 'Is there any Windows SharePoint Services Integration in 2003?' 
  from msp_web_admin where WADMIN_CURRENT_STS_SERVER_ID <> -1

--Number of linked issues, risks, documents 
-- (indicates how much Windows SharePoint Services integration is used)
select count(*) as 
  'Number of linked Windows SharePoint Services issues/risks/documents in 2003' 
  from MSP_WEB_OBJECT_LINKS

--Number of custom Project Web Access views
select count(*) as 'Number of customer Projet Web Access views in 2003' 
  from MSP_WEB_VIEW_REPORTS where WVIEW_ID > 100