# Datatime export error

**URL:** <https://community.spicecrm.io/t/datatime-export-error/153>\
**Category:** KReporter\
**Created:** [July 12, 2017, 2:57pm UTC](https://community.spicecrm.io/t/datatime-export-error/153 "2017-07-12T14:57:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ralph](https://avatars.discourse-cdn.com/v4/letter/r/f475e1/32.png) [@ralph](https://community.spicecrm.io/u/ralph)\
**Post date:** [July 12, 2017, 2:57pm UTC](https://community.spicecrm.io/t/datatime-export-error/153/1 "2017-07-12T14:57:49Z")

</div>

Hi,  
We are using kreporter v3.1 and we have a situation:

We have a report that shows different data such as a datatime.  
We understand that when a datatime is entered into sugarcrm, sugarcrm saves the time in gmt +0 and then the same sugarcrm adds the time zone of each user, for example gmt +2 in summer time in our case.  
Therefore, in sugarcrm you enter “12:30”, sugarcrm saves it as “10:30” and both sugarcrm as kreporter shows “12:30”.  
So far everything is right.

But when this report is exported to CSV, export does not take the time that the kreporter has listed but instead takes the time in gmt +0 and therefore CSV exports “10:30” when in fact it should export "12:30 ".

Is this a bug in v3.1?  
Is there any solution that does not involve doing an update of the version?

Thanks.

---

<div class="post-metadata">

**Author:** ![maretval](https://avatars.discourse-cdn.com/v4/letter/m/b38774/32.png) [@maretval](https://community.spicecrm.io/u/maretval)\
**Post date:** [July 13, 2017, 6:07pm UTC](https://community.spicecrm.io/t/datatime-export-error/153/2 "2017-07-13T18:07:04Z")

</div>

Ralph,  
I had a look at the csv export under KReporter 3.1.0  
Datetime values in CSV are corerct. In Reportview they are wrong.  
Following example date\_entered 23.11.2016 10:14 UTC  
Display in Report 23.11.2016 12:14 (my User has Europe/Vienna as timezone). This means gmt +1 in winter and gmt +2 in summer. It should display 23.11.2016 11:14.  
CSV export =\> 23.11.2016 11:14 That is correct.

Error is somewhere is javascript and I can’t debug that for a 3.1.0. Sorry.

What you can do is set datetimeUTC in present \> override type.  
At least date time would have a correct value. You probably import teh csv to excel, they’re shall a way to convert the value to proper datetime zone.

Val
