Change Management Assignee or Category
I have been working through all of the database tables (both ServiceManager and ServiceManagement) to try to query specific data about upcoming Change Requests (CR's). However, between the two databases, I am stuck.
When querying the ServiceManager database, I am unable to find the right tables to join the Change Category (Normal, Emergency, etc) to my report. I can get the Change Category when I use the ServiceManagement database, but then I lose the ability to get the Assignee information. I know that I am missing a small crucial piece of information.
I have attached the two SQL queries for review.
Any help would be GREATLY appreciated!
Best Answer
-
Metro_ITS Customer IT Monkey ✭
Thank you for all the help Shane. I finally found the right tables that I needed to join to get the information I wanted. IN case anyone else is interested, I have attached the full SQL query for Open Change Requests that are waiting on CAB Approval.
5
Answers
My advice would be to run at the dbo.workitem table in the Service Management database as you won't need to do half as many joins as you are currently doing. I have tried writing the SQL for you but I do not have any Review Activities with Cab Review as the Title haha so give this a try and let me know what you think:
Thanks,
Shane.
Thank you for the quick reply Shane. The script you have above works, but it is one that I already have that was included in the attached file. I am challenged with adding the Change Category (Normal, Emergency, etc) into this same query.
I can find the Category names in the DisplayString table easy enough. However, what I cannot find are the correct primary/foreign keys to join together to associate the Category with the Change Request.
Does this help expand the actual issue I am experiencing a bit more sir? Thanks again for any help you can provide.
The @LanguageCode will pick up the Local User Language that they are running on the Portal.
Let me know if this is what you are after.
Thanks,
Shane.
@Shane_White
Thank you for all the help Shane. I finally found the right tables that I needed to join to get the information I wanted. IN case anyone else is interested, I have attached the full SQL query for Open Change Requests that are waiting on CAB Approval.