Time or time_sec show up as sth like unixtime but MySQL holds DATETIME

The 1562599500000 is the Unix time stamp, which is in the number of seconds since January 1, 1970.

Internally Grafana is using this kind format for time (as do many database programs) which takes up less space and makes time comparisons possible in a single test unlike the human readable forms.

Now on to what I believe is your real problem because I ran into it myself. Most likely your data is not showing up because your dates are in local time, and Grafana wants them in UTC time, and the default time range for the graph is the last 6 hours. For me being in California the offset is 7 hours, just outside of what it was displaying. Switching the “Today” for the graph range showed my data, shifted by the 7 hours.

If this is your problem you have a couple choices. One is to convert your dates to UTC before putting them in your database.

The other is to convert them to UTC in the Grafana query.
SELECT CONVERT_TZ( NOW(), @@session.time_zone, ‘+00:00’ )

NOW() above would be changed to your date field in your database.

Note I just noticed that the time stamp has a few extra zeros.
A normal Unix time stamp for a date around now would have 10 digits like this:
1562599500 (which BTW is Mon Jul 8 08:25:00 2019 Pacific time).
The extra 000 must be used if it wants to go into milliseconds.