Service Desk Practitioners Forum
cancel
Showing results for 
Search instead for 
Did you mean: 

Import Persons and Mobile phonenumbers from Active Directory

SOLVED
Go to solution
Highlighted
Sander Brokke_2
Super Collector

Import Persons and Mobile phonenumbers from Active Directory

Hello All,

Please help me on this issue: I try to import persons and 2 related phonenumbers from Active directory. In active directory all this information is stored in one record. In HP Service Desk a seperation must be made between person and phonenumber because these are stored in different items. Therefor 3 classes are defined in the .ini file: the person itself, the business phone number and the mobile phone number. For each class I created an entry in the import mapping and a dedicated template. Everything works fine, except the import of the mobile phone numbers. This class has it's own mapping and template. The template contains the value "mobile" for phone type. Despite of all these settings, the mobile phone numbers will overwrite the allready imported businessphone number and the type is still set to "business phone". In the desired situation the import results in one person with 2 related phonenumbers: one business phone number and one mobile phone number. To make things more clear I attached the .ini file ato this message.

Any advise on this issue is very welcome. Thanks in advance.
13 REPLIES
Tulio Quinones
Frequent Visitor

Re: Import Persons and Mobile phonenumbers from Active Directory

Can you post a screen shot of your import mapping?

Thanks
Sander Brokke_2
Super Collector

Re: Import Persons and Mobile phonenumbers from Active Directory

Thanks for your reaction. here is the screenshot of the import mapping. Hope this is usefull.
Sander Brokke_2
Super Collector

Re: Import Persons and Mobile phonenumbers from Active Directory

sure, here it is.
Vasily Kamenev
Honored Contributor

Re: Import Persons and Mobile phonenumbers from Active Directory

Hi
Add two new records in ini:
to [MED_TEL] the ATT=...., 'Bussines' = [type] and to [[MOB_TEL] ATT = ..., 'Mobile' = [type], add column [type] in Source and edit mapping too. suppose it help.
Vassili
Sander Brokke_2
Super Collector

Re: Import Persons and Mobile phonenumbers from Active Directory

Hello Vasilli,
Thanks for your help. You offered a solution I was also thinking about, but when I try to do this I get an other error message (See attached picture). For some reason it doesn't like the [type] collumn. I also tried it the other way around: ATT=[type]='mobile' but this didn't solve the problem. Any new ideas?
Thanks,

Sander
Sander Brokke_2
Super Collector

Re: Import Persons and Mobile phonenumbers from Active Directory

Hello Vassili,
Thanks for your help. You offered a solution I was also thinking about, but when I try to do this I get an other error message (See attached picture). For some reason it doesn't like the [type] collumn. I also tried it the other way around: ATT=[type]='mobile' but this didn't solve the problem. Any new ideas?
Thanks,

Sander
Vasily Kamenev
Honored Contributor

Re: Import Persons and Mobile phonenumbers from Active Directory

hi. look at this :
[MOB_TEL]
Source=ADUsers
COLUMNS=[mobile], [samAccountName] , [type]
ATT=[mobile], [samAccountName], 'Mobile' as [type]
CONDITION=[mobile]!='NULL'
Vasily
Jasper Verweij
Honored Contributor

Re: Import Persons and Mobile phonenumbers from Active Directory

Sander,

This is related to your key binding.

Imagine following person-telephone list:

PERSONA 1234 Business
PERSONA 2345 Mobile
PERSONB 1234 Business
PERSONC 1234 Business

Option 1 - Key binding on person (your configuration)
--------------------------------
End result:
PERSONA 2345 Mobile
PERSONB 1234 Business
PERSONC 1234 Business

Conclusion: Only works when you only want to relate 1 number to person. Fails when importing more than 1 number, Fails as well when person already has more than 1 number related in HPSD. Advantage of this approach is however that you can change a number with import when this number changed for this person for real.

Option 2 - Key binding on number (your configuration)
---------------------------------------
End result:
PERSONA 2345 Mobile
PERSONC 1234 Business

Conclusion: Only works when you are certain every person has unique telephone number. Fails when you have non-unique numbers. Old numbers are stored as well with person record, because they are not removed during update. Fails as well when same number is already related to two persons in HPSD. Another side effect is that import process imports telephone numbers also when no person could be found.

Option 3 - Key binding on Person and Telephone Type
---------------------------------------
End result:
PERSONA 1234 Business
PERSONA 2345 Mobile
PERSONB 1234 Business
PERSONC 1234 Business

Conclusion:
Works OK to relate multiple numbers (one per telephone type) to person. Fails when person has more than 1 number with same telephone type. This approach also works to update old numbers with new numbers.



Overall conclusion:
Do key binding on telephone type and person

Jasper

Sander Brokke_2
Super Collector

Re: Import Persons and Mobile phonenumbers from Active Directory

Hello,

This doesn't make a diffence. Still got the same error message. This is wat the ini file looks like:

[MED_TEL]
Source=ADUsers
COLUMNS=[telephoneNumber], [samAccountName], [type]
ATT=[telephoneNumber], [samAccountName],'zaak' as [type]
CONDITION=[telephoneNumber]!='NULL'

[MOB_TEL]
Source=ADUsers
COLUMNS=[mobile], [samAccountName], [type]
ATT=[mobile], [samAccountName], 'mobiel' as [type]
CONDITION=[mobile]!='NULL'
Sander Brokke_2
Super Collector

Re: Import Persons and Mobile phonenumbers from Active Directory

Hello Jasper,

Thanks for your clear answer to my question. I agree with you that key binding on accountname and telephone type is the best solution. Now, I still have one problem left: I need to "generate" the telephone type while extracting data from Active directory (SQL odbc) (see my and Vassili's previous postings). Any suggestions on this issue?
Vasily Kamenev
Honored Contributor
Solution

Re: Import Persons and Mobile phonenumbers from Active Directory

Oh sorry I did mistake:
[MOB_TEL]
Source=ADUsers
COLUMNS=[mobile], [samAccountName] , 'Mobile' AS [type]
ATT=[mobile], [samAccountName], [type]
CONDITION=[mobile]!='NULL'

Vasily
Sander Brokke_2
Super Collector

Re: Import Persons and Mobile phonenumbers from Active Directory

Thank you all! Finally I got it working. The switch in the ini file ("[YPE] as....." fom att -> columns) was necessary. Key's om both accountname and phone type for the classes MED_TEL and MOB_TEL made correct import possible.

Many thanks,

Sander Brokke
Sander Brokke_2
Super Collector

Re: Import Persons and Mobile phonenumbers from Active Directory

Solution offered. See last posting for a summary of the solution
//Add this to "OnDomLoad" event