# OpenPDC Historian Timestamp format : Unable to convert time to an understandable value

**URL:** <http://discussions.gridprotectionalliance.org/t/openpdc-historian-timestamp-format-unable-to-convert-time-to-an-understandable-value/149>\
**Category:** openPDC\
**Created:** [April 5, 2017, 10:17pm UTC](http://discussions.gridprotectionalliance.org/t/openpdc-historian-timestamp-format-unable-to-convert-time-to-an-understandable-value/149 "2017-04-05T22:17:50Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![hasalaid](http://discussions.gridprotectionalliance.org/user_avatar/discussions.gridprotectionalliance.org/hasalaid/32/993_2.png) [@hasalaid](http://discussions.gridprotectionalliance.org/u/hasalaid)\
**Post date:** [April 5, 2017, 10:17pm UTC](http://discussions.gridprotectionalliance.org/t/openpdc-historian-timestamp-format-unable-to-convert-time-to-an-understandable-value/149/1 "2017-04-05T22:17:50Z")

</div>

Hi,

The problem is that OpenPDC (historian) changes the data format of the timestamp, to a format different from those output by PMUs. We get the proper time frame when we check it using both pmu tester and OpenPDC graph visualizer, but when we get the values from the historian (MySQL database) the timestamp value does not relate to any time format.

To clarify the problem:

Our data samples (Ado output adapter-Mysql database) looks like below.

PMU ID TIMESTAMP Value (angle)  
6dbfb2e6-4f1d-4e5e-ae60-eefd5fe81c15 636268434320000000 -91.08

Many Thanks,  
Hasala

---

<div class="post-metadata">

**Author:** ![StephenCWills](http://discussions.gridprotectionalliance.org/user_avatar/discussions.gridprotectionalliance.org/stephencwills/32/20_2.png) [@StephenCWills](http://discussions.gridprotectionalliance.org/u/StephenCWills)\
**Post date:** [April 5, 2017, 10:45pm UTC](http://discussions.gridprotectionalliance.org/t/openpdc-historian-timestamp-format-unable-to-convert-time-to-an-understandable-value/149/2 "2017-04-05T22:45:29Z")

</div>

Hi Hasala,

The value in your TIMESTAMP column looks like it’s in ticks, which is 100-nanosecond intervals since midnight on 01-01-0001. The adapter is designed to use ticks if you specify `timestampFormat=null` in the connection string for the adapter.

You can also specify other formats.  
Standard formats: [https://msdn.microsoft.com/en-us/library/az4se3k1(v=vs.110).aspx](https://msdn.microsoft.com/en-us/library/az4se3k1(v=vs.110).aspx)  
Custom formats: [https://msdn.microsoft.com/en-us/library/8kb3ddd4(v=vs.110).aspx](https://msdn.microsoft.com/en-us/library/8kb3ddd4(v=vs.110).aspx)

The default format, if you do not specify anything for the timestampFormat in the connection string, is a custom format of `dd-MMM-yyyy HH:mm:ss.fff` which should produce timestamps like “05-Apr-2017 18:37:50.164”.

Thanks,  
Stephen
