<div dir="ltr">Thanks for the reply. That certainly places a lot of limits on what can and cannot be done.<div><br></div><div>Calvin</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Apr 29, 2021 at 2:18 PM Even Rouault <<a href="mailto:even.rouault@spatialys.com">even.rouault@spatialys.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br>
>  but the question I have is whether a vector layer were saved to <br>
> something like a GPKG would the timezone even be preserved?<br>
<br>
Short answer: not by default<br>
<br>
Longer answer:<br>
<br>
- see <a href="https://github.com/opengeospatial/geopackage/issues/530" rel="noreferrer" target="_blank">https://github.com/opengeospatial/geopackage/issues/530</a><br>
<br>
- and <a href="https://github.com/OSGeo/gdal/issues/3423#issuecomment-772405674" rel="noreferrer" target="_blank">https://github.com/OSGeo/gdal/issues/3423#issuecomment-772405674</a><br>
<br>
- and <a href="https://gdal.org/drivers/vector/gpkg.html#dataset-creation-options" rel="noreferrer" target="_blank">https://gdal.org/drivers/vector/gpkg.html#dataset-creation-options</a><br>
<br>
So basically:<br>
<br>
- the GeoPackage spec only supports date/time encoded as ISO 8601 with <br>
Zulu timezone : "YYYY-MM-DDTHH:MM:SS.SSSZ"<br>
<br>
- on reading side, the OGR Geopackage driver can understand non-Zulu <br>
timezones<br>
<br>
- on writing side, by default the OGR Geopackage driver will convert <br>
datetimes to the Zulu timezone (applying the appropriate shift), unless <br>
the DATETIME_FORMAT=WITH_TZ dataset creation option is passed at <br>
creation time, in which case the original timezone is preserved. Such <br>
datasets may not be read correctly by third party implementations.<br>
<br>
Even<br>
<br>
<br>
<a href="http://www.spatialys.com" rel="noreferrer" target="_blank">http://www.spatialys.com</a><br>
My software is free, but my time generally not.<br>
<br>
</blockquote></div>