Unsolved How to read MySQL Polygon value with Qt?
-
Hi all,
I have to read POLYGON entries from a mySQL DB.
But POLYGON (as JSON) are not supported by Qt SQL plugin, AFAIK.
What is the best way to achieve this?Is there someone how has experience with this.
Thanks for any advice. -
The
POLYGON
field is of type FIELD_TYPE_GEOMETRY when I'm correct (QTBUG-72140). So you should be able to retrieve it as QByteArray (when flagged as binary) or QString (otherwise) since Qt5.15.0. See https://codereview.qt-project.org/c/qt/qtbase/+/277276 -
@Christian-Ehrlicher Too bad for me, I have to deal with an old Qt version (5.5).
Updating Qt version is not really an option, there are too many other softwares which are impacted.
Anyway, thanks for the links.
-
Since the patch is trivial you can maybe add it to your Qt version?
-
@Christian-Ehrlicher said in How to read MySQL Polygon value with Qt?:
Since the patch is trivial you can maybe add it to your Qt version?
I will take a closer look at this, maybe it is the best way to go.