Service Desk Practitioners Forum
cancel

SD 4.5 SP 23 Import mapping for code type attributes

Highlighted
Raman Shcharbak
Honored Contributor.

SD 4.5 SP 23 Import mapping for code type attributes

Hi! I need a help in a following:
When i import data i need to fill several attributes of type CODE. For now i`ve only managed to do this using 'VALUE mapping' in ATTRIBUTE mapping for code fields. My codes are really huge, so value mapping is not the best decision for me.
The values in source data are equal to code text. If I try to import data without using VALUE mapping and (whith empty 'Reference to Item' or with 'Reference to Item' set to TEXT) i get this error in import window:
warning: Program error: the attribute 'Format' of this Configuration Item cannot be modified, because the Configuration Item item was opened in view mode or because the attribute is read-only.
while processing attribute FORMAT

Am I mistaken? Where?
Thanks in advance
5 REPLIES
Raman Shcharbak
Honored Contributor.

Re: SD 4.5 SP 23 Import mapping for code type attributes

The problem situation is not full.
I forgot to mention, that this code fields are active only for certain categories.. So, initial import shows this error while there are no errors during second "OWERWRITING" import (as category field is already defined for the item). This happened when I tested import using value mapping and, as i wrote above, I mistakenly thought that this method worked.
Now i can see this methods to do the job:
1. Run import 2 times
2. Enable all fields for all categories

3. Find a way to accept the values for that fields (that enabled not for all categories) during import.. may be by forcing category field to be filled First..

Do you have any ideas concering 3rd method? Category field in source xml file is first among item attributes. There is no way to define attr order in import mapping... (I ve even tried to export 'import mapping' via ACES, changed attr mappings order and import again - did not help :( )
Mike Bush
Acclaimed Contributor.

Re: SD 4.5 SP 23 Import mapping for code type attributes

Roman - I'm afraid when I hit this I chickened out and temporarily enabled the fields for all Categories, putting them back after import.

BUT - since then, for another reason, I believe I have proved to myself that the fields in an Import Mapping are filled IN THE ORDER YOU ATTACH THEM TO THE MAPPING. So you MIGHT like to try rebuilding the mapping with CAT attached before CODE - just might work but I feel earlier option is more foolproof.
Raman Shcharbak
Honored Contributor.

Re: SD 4.5 SP 23 Import mapping for code type attributes

Thank you Mike for your experience. But i know that category mapping was "attached" definitely before this code field (as i tried simple import of just several required fields first). This didn`t help.
Mike Bush
Acclaimed Contributor.

Re: SD 4.5 SP 23 Import mapping for code type attributes

OK, so we seem to agree that the "code" which decides when the CODE field should be enabled won't fire correctly during import. I suspect you have no choice but to enable for all Cats.
Raman Shcharbak
Honored Contributor.

Re: SD 4.5 SP 23 Import mapping for code type attributes

There is one more choice - to run import 2 times $). Thanks Mike.
Now I will wait for other experts opinions.