Get a first look at what's coming. The Developer Passport Australia Release Preview kicks off March 12. Dive in! 

Query a record (CI) where sysid of CI is not in table

User310379
Tera Contributor

Let me try to explain.

 

I am using an Orchestrator Query activity which takes a table name, encoded query and a Record Limit.

 

The table I want to query has configuration items that are linked to the Affected CI's in a Change Record (or Change Task) but one of the properties (or columns - not sure of the term) is headed Configuration Item but just shows me the Name of the CI.

 

I need to pull back the actual CI.  One issue is that we have multiple CI's with the same name.  They are different classes of objects, so I have to do a search at the moment for the name, but that could bring back multiple CI's.  I just want to pull back the actual CI that is affected (and in this task_ci table).

 

From what I have read, I think this may be some kind of glide and the "Configuration Item" column may be the record, but just displaying the name.

 

Is there any way, within the encoded query parameter that I can get at the sysid of the actual CI from the column Configuration Item?

 

 

1 ACCEPTED SOLUTION

pavani_paluri
Tera Guru

Hi @User310379 ,

 

In your Orchestrator Query activity, target the task_ci table.
Use the encoded query to filter by the Change Request or Change Task you’re working with.

When you pull back records, include the ci_item (or configuration_item) field.
Even though it shows the Name in the UI, the actual value returned is the sys_id of the CI.
You can then use that sys_id to query the cmdb_ci table directly and get the exact CI record.

 

“Configuration Item” column is a reference field. It stores the CI’s sys_id, not just the name. You’ll need to query the task_ci table, grab the sys_id from the reference field, and then use that sys_id to pull the actual CI from cmdb_ci.

 

 

Mark it helpful if this helps you to understand. Accept solution if this give you the answer you're looking for
Kind Regards,
Pavani P

View solution in original post

1 REPLY 1

pavani_paluri
Tera Guru

Hi @User310379 ,

 

In your Orchestrator Query activity, target the task_ci table.
Use the encoded query to filter by the Change Request or Change Task you’re working with.

When you pull back records, include the ci_item (or configuration_item) field.
Even though it shows the Name in the UI, the actual value returned is the sys_id of the CI.
You can then use that sys_id to query the cmdb_ci table directly and get the exact CI record.

 

“Configuration Item” column is a reference field. It stores the CI’s sys_id, not just the name. You’ll need to query the task_ci table, grab the sys_id from the reference field, and then use that sys_id to pull the actual CI from cmdb_ci.

 

 

Mark it helpful if this helps you to understand. Accept solution if this give you the answer you're looking for
Kind Regards,
Pavani P