Home > database >  How to find the SQL homework,! Genuflect is begged!!!!! High marks
How to find the SQL homework,! Genuflect is begged!!!!! High marks

Time:05-20

The original database for SQL SERVER 2008 r2, MDF and LOG files are,

On the SERVER, SQL SERVER 2012, but until 2008 the inside of the r2 work I can't find it,

Is there any way you can find your homework? Homework is SQL code inside,

CodePudding user response:

File is ok, it is ok to attach,
Below, find the MDF file is attached,

CodePudding user response:

1. Find the MSDB database database file:
MSDBData. MDF
MSDBLog. LDF

2. Attached to the existing database instance, the new database name cannot be MSDB, need to rename it.

3. In the new database instance, the query system tables,
 
Use new database [name]
The select JobName=a.n ame,
StepID=b.s tep_id,
StepName=b.s tep_name,
DatabaseName=b.d atabase_name,
Mand Command=b.com
The from dbo. Sysjobs a
The join dbo. Sysjobsteps b
On a. ob_id=b.j ob_id
Where a.e nabled=1
The order by a.n ame, b.s tep_id

CodePudding user response:

Two methods are tried, no, but I still thank you!

CodePudding user response:

Can you tell me what problems?

CodePudding user response:

Find the original MSDB. MDF
And then find a new test machine, or test cases, cover MSDB with this file directly;
Then you click on the job, found out his homework;
Finally, with the object explorer details, the script for the mass production create a job, get;

CodePudding user response:

The
sunny day 8 reference 5 floor response:
find original MSDB. MDF
And then find a new test machine, or test cases, cover MSDB with this file directly;
Then you click on the job, found out his homework;
Finally, with the object explorer details, the script for the mass production create a job, get;

LDF will together
(1) close test instance
(2) the original MSDB MDF, LDF replacement, coverage testing server/test instance MSDB file
(3) start the SQL server service, and then refresh the homework; Can see the homework before
(4) and then use the object explorer details, batch right click generate to create job script; Preserved to go where you need to create a use
  • Related