# Calendar Data Field - Minute resolution only?

**URL:** <https://forum.inductiveautomation.com/t/calendar-data-field-minute-resolution-only/9381>\
**Category:** Ignition\
**Created:** [November 25, 2014, 3:26pm UTC](https://forum.inductiveautomation.com/t/calendar-data-field-minute-resolution-only/9381 "2014-11-25T15:26:02Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Paullys50](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paullys50/32/3324_2.png) [@Paullys50](https://forum.inductiveautomation.com/u/Paullys50)\
**Post date:** [November 25, 2014, 3:26pm UTC](https://forum.inductiveautomation.com/t/calendar-data-field-minute-resolution-only/9381/1 "2014-11-25T15:26:02Z")

</div>

Hey all, I’m using a calendar entry to populate a datetime column in an SQL database. The format of the calendar entry is Month/Day/Year HH:MM. When the operator selected date is entered into the SQL table, I want to the seconds/milliseconds to be at 0. So 12/1/201 11:05 is entered into the table with 0 seconds, 0 milliseconds.

How can I set those values to 0 upon database entry?

I am using a button with a python script to create an insert query to put the data into a table.

---

<div class="post-metadata">

**Author:** ![SeanT](https://avatars.discourse-cdn.com/v4/letter/s/df788c/32.png) [@SeanT](https://forum.inductiveautomation.com/u/SeanT)\
**Post date:** [November 25, 2014, 4:58pm UTC](https://forum.inductiveautomation.com/t/calendar-data-field-minute-resolution-only/9381/2 "2014-11-25T16:58:52Z")

</div>

Your database doesn’t format your column like DATE HH:MM:SS automatically when you select? If I insert something like ‘2014-11-25 11:57’ into a timestamp column (postgres), I still get ‘2014-11-25 11:57:00’ when I select. Similarly, if I insert ‘2014-11-25’, I get back ‘2014-11-25 00:00:00’ when I select.

---

<div class="post-metadata">

**Author:** ![Paullys50](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paullys50/32/3324_2.png) [@Paullys50](https://forum.inductiveautomation.com/u/Paullys50)\
**Post date:** [November 25, 2014, 5:14pm UTC](https://forum.inductiveautomation.com/t/calendar-data-field-minute-resolution-only/9381/3 "2014-11-25T17:14:34Z")

</div>

The issue was related to how I was initializing the calendar date. It was capturing the current time + 5 minutes. This where I was getting the additional seconds/milliseconds. I’m now doing a CONVERT() function on the initialization.
