在查询分析器中输入
select @@version
或者输入 print @@version
如果是安装过SP4的补丁。应该是下面的信息:
Microsoft SQL Server 2000 - 8.00.2039 (Intel X86)
May 3 2005 23:18:38
Copyright (c) 1988-2003 Microsoft Corporation
Enterprise Edition on Windows NT 5.2 (Build 3790: Service Pack 1)
其他版本信息如下
6.50.201 SQL Server 6.5 RTM
6.50.213 SQL Server 6.5 with Service Pack 1
6.50.240 SQL Server 6.5 with Service Pack 2
6.50.258 SQL Server 6.5 with Service Pack 3
6.50.281 SQL Server 6.5 with Service Pack 4
6.50.415 SQL Server 6.5 with Service Pack 5
6.50.416 SQL Server 6.5 with Service Pack 5a
7.00.623 SQL Server 7.0 / MSDE 1.0 RTM
7.00.699 SQL Server 7.0 SP1 July 1999
7.00.842 SQL Server 7.0 SP2 March 20th, 2000
7.00.961 SQL Server 7.0 SP3 December 15th, 2000
7.00.1063 SQL Server 7.0 SP4
8.00.194 SQL Server 2000 RTM
8.00.384 SQL Server 2000 SP1
8.00.534 SQL Server 2000 SP2 November 30th, 2001
8.00.760 SQL Server 2000 SP3
8.00.2039 SQL Server 2000 SP4
本文链接
创建 对于 JobStep“子计划”失败。 (Microsoft.SqlServer.MaintenancePlanTasks)
有关帮助信息,请单击: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.1399.00&Evtsrc=/blog_article/Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=创建 JobStep&LinkId=20476_/p/index.html>
程序位置:
在 Microsoft.SqlServer.Management.DatabaseMaintenance.MaintenancePlanSubPlan.AddAgentJob(ServerConnection localConnObj, String proxyName) 在 Microsoft.SqlServer.Management.DatabaseMaintenance.MaintenancePlanSubPlan..ctor(String subplanName, String proxyAccount, Package package, ServerConnection localConnObj) 在 Microsoft.SqlServer.Management.DatabaseMaintenance.MaintenancePlan.AddSubPlan(String subplanName, String proxyAccount) 在 Microsoft.SqlServer.Management.MaintenancePlanWizard.MaintenancePlanWizardForm.PerformActions()
执行 Transact-SQL 语句或批处理时发生了异常。 (Microsoft.SqlServer.ConnectionInfo)
程序位置:
在 Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteNonQuery(String sqlCommand, ExecutionTypes executionType) 在 Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteNonQuery(StringCollection sqlCommands, ExecutionTypes executionType) 在 Microsoft.SqlServer.Management.Smo.ExecutionManager.ExecuteNonQuery(StringCollection queries) 在 Microsoft.SqlServer.Management.Smo.SqlSmoObject.ExecuteNonQuery(StringCollection queries, Boolean includeDbContext) 在 Microsoft.SqlServer.Management.Smo.SqlSmoObject.CreateImplFinish(StringCollection createQuery, ScriptingOptions so) 在 Microsoft.SqlServer.Management.Smo.SqlSmoObject.CreateImpl()
指定的 '@subsystem' 无效(有效值由 sp_enum_sqlagent_subsystems 返回)。 (.Net SqlClient Data Provider)
有关帮助信息,请单击: http://go.microsoft.com/fwlinkProdName=Microsoft+SQL+Server&ProdVer=09.00.1399&Evtsrc=/blog_article/MSSQLServer&EvtID=14234&LinkId=20476_/p/index.html>
服务器名称: EYFY 错误号: 14234 严重性: 16 状态: 1 过程: sp_verify_subsystem 行号: 28
程序位置:
在 System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) 在 System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) 在 System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) 在 System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) 在 System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async) 在 System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe) 在 System.Data.SqlClient.SqlCommand.ExecuteNonQuery() 在 Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteNonQuery(String sqlCommand, ExecutionTypes executionType)
根据里面的连接访问微软的错误信息库未发现有用的信息....
在网上搜索一番之后终于知道原因了.....
原因 安装 SQL Server 2005 不安装 SQL Server 2005 Integration Services (SSIS) 服务时出现此问题。 以下代码创建维护计划, 时运行。 此代码试图访问 IntegrationServices 服务。 EXEC msdb.dbo.sp_update_jobstep @job_name=N'System DB Maintenance Plan', @step_id=1 , @subsystem=N'SSIS', @command=N'/SQL "\Maintenance Plans\System DB Maintenance Plan" /SERVER ASHBSQL701 /MAXCONCURRENT " -1 " /CHECKPOINTING OFF'解决方案 要解决此问题, 从 SQL Server 2005 光盘安装 IntegrationServices 服务。 要这样做, 请按照下列步骤操作:
1. 运行 SQLServer 安装向导。
2. 在完成扫描后在系统配置检查页上, 单击 下一步 。
3. 在 名称 框和 公司 框, 中输入适当的信息, 然后单击 下一步 。
4. 单击以选中 IntegrationServices 复选框, 然后单击 下一步 。
5. 单击 下一步 , 然后单击 安装 。
6. 完成安装后, 单击 下一步 , 然后单击 完成 。
本文链接
A JOIN is a means for combining fields from two tables by using values common to each. ANSI standard SQL specifies four types of JOIN: INNER, OUTER, LEFT and RIGHT. As a special case, a table can JOIN to itself in a self-join.
The following is the SQL to create two tables:
CREATE TABLE department
(
DepartmentID INT,
DepartmentName VARCHAR(20)
);
CREATE TABLE employee
(
LastName VARCHAR(20),
DepartmentID INT
);
INSERT INTO department(DepartmentID, DepartmentName) VALUES(31, 'Sales');
INSERT INTO department(DepartmentID, DepartmentName) VALUES(33, 'Engineering');
INSERT INTO department(DepartmentID, DepartmentName) VALUES(34, 'Clerical');
INSERT INTO department(DepartmentID, DepartmentName) VALUES(35, 'Marketing');
INSERT INTO employee(LastName, DepartmentID) VALUES('Rafferty', 31);
INSERT INTO employee(LastName, DepartmentID) VALUES('Jones', 33);
INSERT INTO employee(LastName, DepartmentID) VALUES('Steinberg', 33);
INSERT INTO employee(LastName, DepartmentID) VALUES('Robinson', 34);
INSERT INTO employee(LastName, DepartmentID) VALUES('Smith', 34);
INSERT INTO employee(LastName, DepartmentID) VALUES('John', NULL);
Employee table
LastNameDepartmentID
Rafferty
31
Jones
33
Steinberg
33
Robinson
34
Smith
34
John
NULL
Department table
DepartmentIDDepartmentName
31
Sales
33
Engineering
34
Clerical
35
Marketing
- Cross join
CROSS JOIN returns the Cartesian(笛卡儿积) product of rows from tables in the join. In other words, it will produce rows which combine each row from the first table with each roow from the second table.
The CROSS JOIN does not apply any predicate to filter records from the joined table. Programmers can further filter the results of a cross join by using WHERE caluse.
SELECT *
FROM employee CROSS JOIN department;
Employee.LastNameEmployee.DepartmentIDDepartment.DepartmentNameDepartment.DepartmentID
Rafferty
31
Sales
31
Jones
33
Sales
31
Steinberg
33
Sales
31
Smith
34
Sales
31
Robinson
34
Sales
31
John
NULL
Sales
31
Rafferty
31
Engineering
33
Jones
33
Engineering
33
Steinberg
33
Engineering
33
Smith
34
Engineering
33
Robinson
34
Engineering
33
John
NULL
Engineering
33
Rafferty
31
Clerical
34
Jones
33
Clerical
34
Steinberg
33
Clerical
34
Smith
34
Clerical
34
Robinson
34
Clerical
34
John
NULL
Clerical
34
Rafferty
31
Marketing
35
Jones
33
Marketing
35
Steinberg
33
Marketing
35
Smith
34
Marketing
35
Robinson
34
Marketing
35
John