Solved

find out job steps

Posted on 2016-08-05
24
44 Views
Last Modified: 2016-11-23
hi,

I just get an email about a SQL job failure:

SQLAgent - TSQL JobStep (Job 0xB37A49A1542D364BA1637B2AC21C6236 : Step 1)

how can I find that job out ? I can't find that using that number.
0
Comment
Question by:marrowyung
  • 12
  • 8
  • 2
  • +1
24 Comments
 
LVL 17

Accepted Solution

by:
Barry Cunney earned 250 total points
Comment Utility
Hi marrowyung,
Please try the following:

DECLARE @Job uniqueidentifier

SET @Job = 'B37A49A1-542D-364B-A163-7B2AC21C6236' -- Job 0xB37A49A1542D364BA1637B2AC21C6236

SELECT 
j.job_id
,j.name
,js.step_name
,js.command
,js.last_run_date 
FROM sysjobs j
left join sysjobsteps js on js.job_id = j.job_id
where j.job_id = @job

Open in new window

0
 
LVL 65

Expert Comment

by:Jim Horn
Comment Utility
In SSMS, navigate to your server > SQL Server Agent > Jobs, find the job in question,  right-click: View History, and hit the Export button to save the history to a text file.

Then in a decent text editor open the text file.  The error message will still be jibberish-riffic, but at least there will be a 'Source:' and 'Description:' with the error location and message.
0
 
LVL 65

Assisted Solution

by:Jim Horn
Jim Horn earned 125 total points
Comment Utility
Also ... Double-click to open the job, click on Steps in the left nav, eyeball where job step TSQL JobStep is, click on that, hit the Edit button, then in the resulting popup the General Tab > Package textbox will tell you the SSIS package name and location that threw the error.
0
 
LVL 45

Assisted Solution

by:Vitor Montalvão
Vitor Montalvão earned 125 total points
Comment Utility
marrowyung, do you still need help with this question?
0
 
LVL 1

Author Comment

by:marrowyung
Comment Utility
St. Jimbo,

"In SSMS, navigate to your server > SQL Server Agent > Jobs, find the job in question,  right-click: View History, and hit the Export button to save the history to a text file. "

the problem right now is this number is not show as the name, so I can't find where it is

"Then in a decent text editor open the text file"

what is that ?
0
 
LVL 1

Author Comment

by:marrowyung
Comment Utility
Barry Cunney,

"SET @Job = 'B37A49A1-542D-364B-A163-7B2AC21C6236' -- Job 0xB37A49A1542D364BA1637B2AC21C6236"

you just remove the 0x ?
0
 
LVL 45

Expert Comment

by:Vitor Montalvão
Comment Utility
"Then in a decent text editor open the text file"

 what is that ?
I guess anything better than Notepad :)


you just remove the 0x ?
Why not give a try with both so you can see by yourself why '0x' has been removed? ;)
0
 
LVL 1

Author Comment

by:marrowyung
Comment Utility
"Why not give a try with both so you can see by yourself why '0x' has been removed? ;)"

I knew, but without knowing why I think it make sense to clarify what I see.

but tks for that victor, you always proactive. I like that.

I really can't see that job even I use the SQL job filter from SSMS.

the point here is, I can't find the job, that's it.
0
 
LVL 45

Expert Comment

by:Vitor Montalvão
Comment Utility
I really can't see that job even I use the SQL job filter from SSMS.
Can you post what returns from the following query?
USE msdb
GO

SELECT name, job_id 
FROM sysjobs 

Open in new window

0
 
LVL 1

Author Comment

by:marrowyung
Comment Utility
so just focus on job id?
as name and job id diff anyway.
0
 
LVL 45

Expert Comment

by:Vitor Montalvão
Comment Utility
This is only for sanity check.
Can you provide the requested information?
0
 
LVL 1

Author Comment

by:marrowyung
Comment Utility
sth like this:

001EF15F-2C08-4FEB-9C57-777C927D5793      4A02DBD6-498A-44EF-A426-2B1C60E04834
0025044A-EC14-4EF9-BAAF-AA42A2840922      699129CC-58AA-42CA-AD6E-07D91F3E5B3A
00391440-42D0-4FBB-93FB-9861B7931F39      90BE2193-67AB-44CB-857E-4968056A0A31
004421B2-79B1-45A4-AFA9-01553A048CF5      4788A2BA-CDBD-40B7-8D6C-C96CFAE45E8F
004DACFE-534A-489B-8F82-0BEBFFDE2F2D      85F2A4A0-055F-4613-98DF-8C26AE8DA104
0084244E-A427-46D6-BA0D-95F768836F02      6191EEAA-DF9F-4564-AF7B-14EAE215665B
0097C661-ED0E-42CA-84EF-CAD60793D80E      ABCC002E-7B24-4338-88AD-EF68D432A0F0
00E8652A-4CCF-415B-A034-3ACE91FE86F5      1EBE6B62-CFFC-4F0E-8331-27F4E13ECAC3
0124C1B3-812E-4352-B16C-AF191C4145AA      624F027C-B323-4429-8E66-0C1E76D378EC
01316601-797B-4FBE-BB86-749CBCEC8DFF      AABEBF5C-AA64-44B3-9BA8-962FECA70400
0185EF67-75B3-4384-8E64-FAC5F556B481      3C615A10-4AB9-4067-9505-107A4BC51864
01AC28BB-55AA-4C75-808B-8D632A765B35      8940907C-F8C3-42EA-9933-35CF3AD4CC3C
01BED4DE-EADE-4E6E-851A-8797620FA330      C636941B-82EE-420A-81D4-B2A0EB99D6E0
01D63584-BB49-4E97-B468-05A1F5909CDF      1678DD21-CE80-445D-B5B1-2E135057B9AC
01F86704-2DC5-4FF5-B3E5-3DE986232F5B      785A83C7-F040-4BCA-81C3-9F811DAE7DBC
020C3F03-C3EE-424E-8705-B2F987A6FCA8      8D1932F3-11A3-48EF-9E0F-CFD594DE6387
02888B3E-1634-4ACA-9015-A56B1D89EEF2      F93FA980-60E3-460A-8D40-C4820FB3494C
028B9D3B-817C-4416-9238-3B4297A2BF95      A06F4B1B-AB62-447C-9CE1-42B91D585B48
02BDCFBB-9D77-4F1B-AB97-E8106D197987      C4BBF975-C0EA-43B0-894D-A95F4AE60DD3
0
Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

 
LVL 45

Expert Comment

by:Vitor Montalvão
Comment Utility
Are you sure the job is from this SQL Server instance?
Any chance that job belongs to another SQL Server?
0
 
LVL 1

Author Comment

by:marrowyung
Comment Utility
no.. I am sure.
0
 
LVL 1

Author Comment

by:marrowyung
Comment Utility
as  I said,very hard to find out which job it belongs to .
0
 
LVL 45

Expert Comment

by:Vitor Montalvão
Comment Utility
You still receiving the same email with the same job id?
0
 
LVL 1

Author Comment

by:marrowyung
Comment Utility
no. I think I have to learn how to work out the SQL job. so I come back for that.
0
 
LVL 45

Expert Comment

by:Vitor Montalvão
Comment Utility
If you're not receiving more emails and you can't find the job my guess is that job has been deleted.
0
 
LVL 17

Expert Comment

by:Barry Cunney
Comment Utility
Hi marrowyung,
In your very first post, you mentioned that you received this Job ID in an e-mail.
If possible, please post up a print screen of this e-mail.

Thank you
0
 
LVL 45

Expert Comment

by:Vitor Montalvão
Comment Utility
marrowyung, how's this going?
0
 
LVL 1

Author Comment

by:marrowyung
Comment Utility
hi,

forget about that, I think I deleted the message and will come back again for that.
0
 
LVL 1

Author Closing Comment

by:marrowyung
Comment Utility
tks al.
0
 
LVL 1

Author Comment

by:marrowyung
Comment Utility
hi,

I get one more:

"with application name 'SQLAgent - TSQL JobStep (Job 0xB3CB0A4853CE91479D8138B7A261CBC4 : Step 1)' by user"

but I can't  get it return on what SQL job it is by using:

DECLARE @Job uniqueidentifier

SET @Job = 'B3CB0A4853CE91479D8138B7A261CBC4' 

SELECT 
j.job_id
,j.name
,js.step_name
,js.command
,js.last_run_date 
FROM sysjobs j
left join sysjobsteps js on js.job_id = j.job_id
where j.job_id = @job

Open in new window


it said :

Msg 8169, Level 16, State 2, Line 3
Conversion failed when converting from a character string to uniqueidentifier.

Open in new window

0
 
LVL 1

Author Comment

by:marrowyung
Comment Utility
it seems this script can ?


select * from msdb..sysjobs where job_id =  0xB3CB0A4853CE91479D8138B7A261CBC4
0

Featured Post

Free Gift Card with Acronis Backup Purchase!

Backup any data in any location: local and remote systems, physical and virtual servers, private and public clouds, Macs and PCs, tablets and mobile devices, & more! For limited time only, buy any Acronis backup products and get a FREE Amazon/Best Buy gift card worth up to $200!

Join & Write a Comment

Occasionally there is a need to clean table columns, especially if you have inherited legacy data. There are obviously many ways to accomplish that, including elaborate UPDATE queries with anywhere from one to numerous REPLACE functions (even within…
In this article I will describe the Copy Database Wizard method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now