Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个数据库,其中有一列充满经度和纬度坐标的存储方式,如下所示
GEOMETRYCOLLECTION(POINT(-2.1238294 57.1714198))
我想选择整列并只打印出实际坐标,这是如何实现的?
提前致谢
Read the manual:
-- Gets the 1st value from the GEOMETRY COLLECTION SELECT AsText(GeometryN(GeomFromText(your_field), 1)) FROM your_table;