Get actual Job Name from Program Name column of the results while running sp_whoisactive or sp_who2 I am running sp_whoisactive on my Prod and offload the data for analysis.
When I run sp_whoisactive or sp_who2 and if there is any SQL Agent Jobs running it would always display the Program Name like SQLAgent - TSQL JobStep (Job 0x984ECB0C94C14943B787BDE548F77311 : Step 1).
I want  the job name to be displayed there instead of those numbers.
I have to  manually copy that value and run it against select * from msdb..sysjobs where job_id = 0x984ECB0C94C14943B787BDE548F77311
Can any help me with this.
PS: tried to substring only the hexadecimal and convert it to uniqueidentifier and then run it to on the sysjobs tables as a variable but didn't work.
--This is what I tried to do

declare @substring nvarchar(200)   
select @substring = (SUBSTRING(@program,30,34))
select @substring

declare @jobname nvarchar(200) 
select @jobname = (select name from msdb..sysjobs where job_id = convert(uniqueidentifier,@substring))

select @jobname

--Error message

Msg 8169, Level 16, State 2, Line 22
Conversion failed when converting from a character string to uniqueidentifier.
You can do this easily with sp_WhoIsActive.
EXEC dbo.sp_WhoIsActive 
    @get_additional_info = 1, 
    @get_task_info = 2;


If you click on the additional_info column, you'll see this:

You don't explicitly need the @get_task_info parameter to retrieve the extra information, it's just a very useful general combination.