web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Deletion and recreation of the field with same logical name but different data type

(0) ShareShare
ReportReport
Posted on by 17,078

Hi All,

Will deletion of a field and recreation of the field with the same logical name cause any unexpected issues in the source instance as well as while deploying it to solutions already having the deleted field with old data type?

*This post is locked for comments

  • Suggested answer
    Sreevalli Profile Picture
    3,264 on at

    Hi Nithya,

    Need to publish the changes before creating a field with same logical name in the source, also the destination field need to be deleted before importing.

  • Suggested answer
    Rawish Kumar Profile Picture
    13,758 on at

    Hi Nithya,

    Shouldn't be any issue. remember it happens at the database level hence tight violation rules applies.

    when you delete -it gets deleted from the database and leaves no mark.

    However when you delete - make sure the component is not there in target environment because it will be a nightmare.  

  • Suggested answer
    Charles Abi Khirs Profile Picture
    3,569 on at

    Hello,

    In the source, after you delete the field, publish your customization and then create the new field with the same schema name.

    In the destination, you must delete the field before you import the solution; otherwise, the import will give an error because the CRM will try to create this new field and once the system detects that there is a field with the same schema name but different type, It will throw the error.

  • Suggested answer
    KARTHIKGOWTHAM@SUYATITECH Profile Picture
    175 on at

    Hi Nithya,

    To change the data type without any hazzles, I prefer XrmToolBox's Attribute Manager Plugin. Here's how you do it.

    1. Choose the entity, attribute whose data type has to be updated

    2. In the settings section, choose Convert Attribute Type, if you want the data to be preserved, then choose Migrate Data (do this only data types will be compatible)

    3. In the right panel, Steps, you will see 6 steps that will be carried out while doing this. If you want the old data then uncheck the "Remove Temporary Attribute". Post data type migration you can evaluate the data then can manually delete it from your CRM instance

    4. Now choose the target data type in the drop down in Attribute Type Line item.

    5. Once you verify all the steps you did is correct, hit the "Execute Steps" button below the Steps panel in the right hand side

    6. Logs area will display what exactly is happening during the conversion.

    Depending on the amount of data, the time taken to do this conversion may vary.

    For Dev, Staging & Prod instances repeat the same steps by changing the connection in Xrm tool box. Following this way you need not worry about the existing attribute type.

    Regards,

    Karthik

    Mark my answer Verified, if you find this answer helpful

  • Suggested answer
    Dynamics365 Rocker Profile Picture
    7,755 on at

    It will not impact source but you have to delete old data type field from target environment before importing solution.

  • Suggested answer
    Pawar Pravin Profile Picture
    5,237 on at

    Hi Nithya,

    Basically create and delete fields in CRM impact directly on database. You can delete field and create with same logical name BUT MAKE SURE THAT OLD FIELD SHOULD BE DELETED FROM ALL THE INSTANCE else it will not allow to import solution on target instance.

    Also make sure that old field should not been used in any plugin or js coding.

  • Suggested answer
    RaviKashyap Profile Picture
    55,410 Moderator on at

    Hi,

    Haven't tried it yes but I guess Yes you will face issues deploying thye new field in the environment which contains the same field as old data type. As suggested by Pravin above, you need to delete the fields from all the environment before deploying the changes.

    Hope this helps.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
ScottDurow Profile Picture

ScottDurow 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans