Issue
Symptoms
By default, OOB 'Windows OS - Servers' Pattern return Baseboard Serial number, but in some case, customer might wanted to use the Bios Serial number for the CI instead.
Cause
From the 'Windows OS -Server' pattern, step '5. Insert serial number to cmdb_ci_win_server':
Value=$cmdb_serial_number[1].serial_number [we will get the 1st row (baseboard) in the cmdb_serial_number table]
Resolution
There are 2 options:
1) Changed the order/swap these 2 steps (3.10 and 3.12) in the pattern
2) Edit the 'OSs - Pre Sensor' Pattern Pre/Post Script index:
FROM: for(var serialIndex = 0; serialIndex < serialList.length; serialIndex++){
TO: for(var serialIndex = 1; serialIndex < serialList.length; serialIndex++){
https://<instancename>.service-now.com/$sn_pattern_designer.do?sys_id=670e55a4db702200c06776231f961942&authoring_mode=modify&editor_mode=advanced§ion_item_type=identification§ion_item_name=discovery
[Note: attached script here]
Additional Information
Serial Number Valid Field:
https://hi.service-now.com/kb_view.do?sys_kb_id=198e4f97db583b4813b5fb2439961924&sysparm_rank=7&sysparm_tsqueryId=b77a23a7db2dbf084819fb24399619ba