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)

How is date/time field stored? Calculate correct duration between the fields..

(0) ShareShare
ReportReport
Posted on by 886

Hi,

I have a 3rd party solution that stores date/time with a field called start + a field called end. Furthermore a duration field (Date/time) is present that calculates the value between start and end. The problem is (I think) that the start + end date/time fields also contains seconds in the database?

We looked in the database at it seems like a date/time field is stored in seconds also...

If I look in CRM (GUI). I ex. have a start = 11/11-2015 15:08 and end = 11/11-2015 15:18. Some times the duration field can be set to 9 minutes. I guess that's because the date/time is stored in seconds in the database also?

Is there somehow I can "convert" the date/time (Use a workflow to insert the value into a date/time start + end helper field - and insert the value from the helper field into the original start/end field - and in the process should the seconds be stripped out)

*This post is locked for comments

I have the same question (0)
  • ManirajKV Profile Picture
    1,477 on at

    Hi,

    can u elaborate your requirement. ? What do you want to achieve ?

  • rskadk1 Profile Picture
    886 on at

    Hi,

    Thanks for your answer. I wan't to get a correct duration. So start date/time: 11/11-2015 15:08 and end date/time: 11/11-2015 15:18 have a duration of 10 minutes. And not 9 minutes.

    So overall I want to clarify if date/time is stored in seconds in the database or not - causing the 3rd party workflow to fail...

    In the end I wan't to solve this with a standard workflow. If not possible by standard it can be combined with 3rd party workflows.

  • Aiden Kaskela Profile Picture
    19,696 on at

    Hi,

    Seconds are stored in the database. The utility is probably getting back 9 minutes 45 seconds and considering it as 9 minutes because there are 9 minutes in that amount of time.

    Thanks,

     Aiden

  • Suggested answer
    ManirajKV Profile Picture
    1,477 on at

    Hi,

    Try using Calculated field for finding the duration between the start and end date.

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
Varsha deshpande Profile Picture

Varsha deshpande 5

#2
NeerajPawar Profile Picture

NeerajPawar 2

#2
jlattimer Profile Picture

jlattimer 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans