- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-29-2022 05:46 PM
Hi All,
I have a requirement where I need to correct the date in the field "start_date".
Currently the field has future date, Say for example - 02/12/2022 10:11:33 (2nd of Dec) which is 8 month from now. However I need to alter the value from 2nd Dec to 12th Feb and update the start_date with new value for all the affected records. How can I achieve this ? Any suggestion would be very helpful. thanks !!
Hi
Regards,
Sandhya
Solved! Go to Solution.
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-01-2022 09:41 AM
Hi Hitoshi,
Here is what I did to resolve my future date issue.
1. Cleared all the future dated values from start_date.
2. Get the source file with correct data and transform the date values in the system.
3. Created a Business Rule to prevent population of any future date.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-29-2022 08:02 PM
Hi Hitoshi,
The logic is to swap the month and day of current date to day and month respectively on new date for each record if the start_date in future dated. Time remains the same.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-29-2022 08:13 PM
How is the new date calculated or it there a field in the table that has the new date?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-29-2022 08:19 PM
Its a discovery job that captures the date (correct). However during the process of updating CMDB Database, the dates get converted to future date.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-29-2022 08:25 PM
So how should the new date be calculated? If the records were created by discovery, won't it be easier to delete the erroneous records and re-run discovery to re-create them?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-01-2022 09:41 AM
Hi Hitoshi,
Here is what I did to resolve my future date issue.
1. Cleared all the future dated values from start_date.
2. Get the source file with correct data and transform the date values in the system.
3. Created a Business Rule to prevent population of any future date.