- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-22-2025 10:57 AM
When we create a computer CI, the value of install_status is 1 (Installed). As expected, a hardware asset record is created (model category, computer), but the value of state is 2 (On order). It is my understanding that, because of the "Asset CI Install Status Mappings" records, the CI's "Installed" should make the asset "In use". I did verify that there is a two-way mapping of state/install_status for assets/CIs where the state value is "In use" and the install_status value is "Installed". Additionally, I can see that the AssetAndCISynchronizer script include has been updated to reflect the changes recommended in https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0717902.
When I modify the CI's install_status (e.g. Installed to In stock), the asset's state switches correctly. Then, changing the CI back to Installed, the asset is set as "In use".
As far as I can tell, there are no business rules (other than the customized "Update Asset fields on change") or flows setting the asset to 'On order'. Finally, as far as I can tell, the Create Asset on insert BR and AssetandCI script include are OOB.
Why, on insert, are the CIs' install_status not correctly setting the assets'?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-28-2025 12:54 PM
Turns out it was the default value on the field. I thought it should take the value from the CI on creation, but apparently now.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-22-2025 11:29 PM
My PDI is taking ages to wake up, so I can't verify it (yet), but logically thinking, creating the CI isn't done the moment it is handed over to a user. That's done later. So to me, only thinking in real world logic, without validating code in ServiceNow, when you create a CI (computer), it creates the asset, but it only should be set to 'in use' when it's assigned to a user (having it on a shelf in a stockroom, where the computer starts at a company, shouldn't put it in use).
Is there any logic 'on insert' of an asset that maybe sets the status to 'on order' ?
I'll set of the alarm for my PDI again, to see it it will wake up and update you if I find a cause in the OOB code.
Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-28-2025 12:54 PM
Turns out it was the default value on the field. I thought it should take the value from the CI on creation, but apparently now.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-28-2025 08:31 PM
In the Asset CI mapping table you can see the proper mapping between the both tables.