CREATE Proc [dbo].[Proc_StopJob] as begin declare @I int declare @JobID uniqueidentifier -- 1. create temp table to save jobs status create table #job_run_status ( job_id uniqueidentifier not null, last_run_date int not null, last_run_time int not nu
--SQL Server 2008 定时作业的制定 --1.打开[SQL Server Management Studio],在[对象资源管理器]列表中选择[SQL Server 代理]: --2.鼠标右击[SQL Server 代理],选择[启动(S)],如已启动,可以省略此步骤: --3.展开[SQL Server 代理]列表,右击[作业]-->[新建作业]: --3.1 在[常规]选项卡中: -- 输入作业名称,如"My Job": --3.2 在[步骤]选项卡中:
查询作业基本信息和作业执行情况 SELECT [jop].[job_id] AS '作业唯一标识符' ,[jop].[ name ] AS '作业名称' ,[dp].[ name ] AS '作业创建者' ,[cat].[ name ] AS '作业类别' ,[jop].[description] AS '作业描述' , CASE [jop].[enabled] THEN '是' THEN '否' END AS '是否启用' ,[jop].[date_created] AS '作业创建日期' ,
查询作业基本信息和作业执行情况 SELECT [jop].[job_id] AS '作业唯一标识符' ,[jop].[ name ] AS '作业名称' ,[dp].[ name ] AS '作业创建者' ,[cat].[ name ] AS '作业类别' ,[jop].[description] AS '作业描述' , CASE [jop].[enabled] THEN '是' THEN '否' END AS '是否启用' ,[jop].[date_created] AS '作业创建日期' ,
原因: 要一次性update 2千万条数据,虽然update sql很简单,但是由于一次性修改太多的数据,造成数据库log满了,就会报error: [ErrorCode: 9002, SQL State: S0004] The transaction log for database'XXXXData' is full. To find out why space in the log cannot be reused, seethe log_reuse_wait_desc column in
--第一题 查询Student表中的所有记录的Sname.Ssex和Class列.select Sname,Ssex,Class from student --第二题 查询教师所有的单位即不重复的Depart列.select distinct Depart from Teacher --第三题 查询Student表的所有记录.select * from student --第四题 查询Score表中成绩在60到80之间的所有记录.select * from Score where Degree