Adding a new phone type (e.g. a new "Mobile" type) using a Component Manager script will result in redundant columns being added to the Phone table in Sage CRM.


The issue can be reproduced by following the below steps:

1. Create a new Component, in the Component Manager, and set it to be the current Component.

2. Add a Company "Mobile" number, by adding the appropriate translation to the "Link_CompPhon" caption family.
(CaptionCode: Mobile, Caption Family: Link_CompPhone, Caption Family Type: Links, Caption Order: 6 , US/UK Translation: Mobile)

3. Script out the component and add it to another v7.1h copy of sage CRM.

The new Company "Mobile" phone field will now be available, however on checking the "Phone" table you will see the following columns:

- Phon_CountryCodeMobile
- Phon_AreaCodeMobile
- Phon_NumberMobile

These columns are not used by the system.


On examining the scripted component, you will see the following:

Columns that have been added or updated

var EditsId11966 = AddCustom_Edits('Phone','Phon_CountryCodeMobile','46','0','','3','','20','','','');
AddCustom_Data('Custom_Edits', 'ColP', 'ColP_ColPropsId','ColP_ColPropsId, ColP_DataType, ColP_DataSize', EditsId11966+',"",""','1');

var EditsId11967 = AddCustom_Edits('Phone','Phon_AreaCodeMobile','46','0','','4','','20','','','');
AddCustom_Data('Custom_Edits', 'ColP', 'ColP_ColPropsId','ColP_ColPropsId, ColP_DataType, ColP_DataSize', EditsId11967+',"",""','1');

var EditsId11968 = AddCustom_Edits('Phone','Phon_NumberMobile','46','0','','10','','20','','','');
AddCustom_Data('Custom_Edits', 'ColP', 'ColP_ColPropsId','ColP_ColPropsId, ColP_DataType, ColP_DataSize', EditsId11968+',"",""','1');


The issue can be worked around by removing the above lines from your component script.


This issue has been resolved in Sage CRM 7.2b.