Skip to main content
Tweeted twitter.com/StackGIS/status/1531425301867134978
added 26 characters in body
Source Link
Kadir Şahbaz
  • 77.3k
  • 56
  • 249
  • 392

I use this solution to display actual QDateTime value with milliseconds in a temporary memory layer. And I use another solution to export as CSV the value including the millisecond value.

enter image description here

But then, I realized that "Use Date/Time" option changed the type of the time_break field from QDateTime to string when I exported as GeoPackage. But I need a datetime field in the GeoPackage.

Export using "Use Date/Time" option:

enter image description here

Result (converted to string):

enter image description here

If I don't use "Use Date/Time" option, it exports the field as QDateTime, but it changes all millisecond values to zero:

enter image description hereenter image description here

How can I export it as a GeoPackage to contain the datetime field with the actual millisecond value?

I use this solution to display actual QDateTime value with milliseconds in a temporary memory layer. And I use another solution to export as CSV the value including the millisecond value.

But then, I realized that "Use Date/Time" option changed the type of the time_break field from QDateTime to string when I exported as GeoPackage. But I need a datetime field in the GeoPackage.

Export using "Use Date/Time" option:

enter image description here

Result (converted to string):

enter image description here

If I don't use "Use Date/Time" option, it exports the field as QDateTime, but it changes all millisecond values to zero:

enter image description here

How can I export it as a GeoPackage to contain the datetime field with the actual millisecond value?

I use this solution to display actual QDateTime value with milliseconds in a temporary memory layer. And I use another solution to export as CSV the value including the millisecond value.

enter image description here

But then, I realized that "Use Date/Time" option changed the type of the time_break field from QDateTime to string when I exported as GeoPackage. But I need a datetime field in the GeoPackage.

Export using "Use Date/Time" option:

enter image description here

Result (converted to string):

enter image description here

If I don't use "Use Date/Time" option, it exports the field as QDateTime, but it changes all millisecond values to zero:

enter image description here

How can I export it as a GeoPackage to contain the datetime field with the actual millisecond value?

Source Link
Kadir Şahbaz
  • 77.3k
  • 56
  • 249
  • 392

Exporting Geopackage converts milliseconds of QDateTime to zero

I use this solution to display actual QDateTime value with milliseconds in a temporary memory layer. And I use another solution to export as CSV the value including the millisecond value.

But then, I realized that "Use Date/Time" option changed the type of the time_break field from QDateTime to string when I exported as GeoPackage. But I need a datetime field in the GeoPackage.

Export using "Use Date/Time" option:

enter image description here

Result (converted to string):

enter image description here

If I don't use "Use Date/Time" option, it exports the field as QDateTime, but it changes all millisecond values to zero:

enter image description here

How can I export it as a GeoPackage to contain the datetime field with the actual millisecond value?