Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Change value for all the records created in an year to NEW value on 1st January every year automatically

Posted on by 80

Hi All,

I have a requirement to change the attribute value from NEW to OLD after 31st December every year.

For Example: If the record is created anytime between 1st January to 31st Dec 2016, the value at the time of  creation should be NEW but post 31st Dec 2016 i.e 1st January 2017 - The attribute value should automatically change to OLD.

I think it can be done in 3 ways:

1) Javascript: Problem is the record has to be open to run this functionality. If 10k records are created, this option is not possible.

2) Workflows: Tons of workflows will run through out the year. Can impact performance.

3) Console Appplication - It will run on 31st December which will update the attribute from NEW to OLD.I am thinking to go with this.

What do you think is the best solution?

*This post is locked for comments

  • Verified answer
    Tim Dutcher Profile Picture
    Tim Dutcher 2,100 on at
    RE: Change value for all the records created in an year to NEW value on 1st January every year automatically

    If you have a Windows machine that will be running on 31st Dec 2016 then scheduling a job to run the console app seems fine to me. Just make sure that the credentials you provide are valid on that date.

    If you have other scheduling needs like this then Azure provides lots of ways to handle this. You can schedule a Logic App, Azure Function, Web Job, etc.

  • Verified answer
    PS Profile Picture
    PS 23,577 on at
    RE: Change value for all the records created in an year to NEW value on 1st January every year automatically

    When you search and the system shows 5000+ in the pagination, it does not mean that you have around 5000 records. It can be way more. Just cross check when you export the list.

  • AXCRM1 Profile Picture
    AXCRM1 80 on at
    RE: Change value for all the records created in an year to NEW value on 1st January every year automatically

    Yes, around 5000 records. Thanks Prashant

  • Verified answer
    PS Profile Picture
    PS 23,577 on at
    RE: Change value for all the records created in an year to NEW value on 1st January every year automatically

    You can advanced find the records created between the dates to get a no. and then add new/old column and export>>edit>>import

  • Verified answer
    PS Profile Picture
    PS 23,577 on at
    RE: Change value for all the records created in an year to NEW value on 1st January every year automatically

    Just saw that your question has already been answered...

    Anyways, if you have less than 10K records on online CRM, you can export the list change value from new to old and re-import it.

    If you have on-premise, you can do it for a greater no. of records.

    This is simpler thatn writing a workflow or Javascript or any code.

  • Verified answer
    PS Profile Picture
    PS 23,577 on at
    RE: Change value for all the records created in an year to NEW value on 1st January every year automatically

    How many records do you have? Less than 10K or more than 10K?

    Is it on-premise or online?

  • AXCRM1 Profile Picture
    AXCRM1 80 on at
    RE: Change value for all the records created in an year to NEW value on 1st January every year automatically

    Thank you Mark

  • AXCRM1 Profile Picture
    AXCRM1 80 on at
    RE: Change value for all the records created in an year to NEW value on 1st January every year automatically

    Thank you Alex!

  • Verified answer
    Alex Fun Wei Jie Profile Picture
    Alex Fun Wei Jie 33,626 on at
    RE: Change value for all the records created in an year to NEW value on 1st January every year automatically

    As the record increase from time to time, console application would be better 

    1. Directly update the record through console application

    - to increase the performance beware of 

    2727.2.png

    2727.2.png

    2. Create an on demand workflow, and use console application to call it by passing in the workflow id and the record id. 

    https://msdn.microsoft.com/en-us/library/microsoft.crm.sdk.messages.executeworkflowrequest.aspx

  • Verified answer
    TheMarkChristie Profile Picture
    TheMarkChristie 10,328 on at
    RE: Change value for all the records created in an year to NEW value on 1st January every year automatically

    Hi AXCRM

    If you only need to run it as a one off you could do it as a manual workflow.

    Use crm.fullscope.com/ms-dynamics-crm-2011-bulk-workflow-execution-tool

    which will run any workflow (Timed) on any record entity

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,235 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans