Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7786199
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T20:22:40+00:00 2026-06-01T20:22:40+00:00

I have searched high and low for a clue to or even the answer

  • 0

I have searched high and low for a clue to or even the answer to the following question and have got nowhere so hence me asking on here.

Basically, I’m trying to populate a Geometry column in MySQL with a polygon. But whatever i try, the column end up with a value of NULL rather than what it is supposed to be.

It looks to me like the points for a Polygon cannot contain decimals such as Latitude and Longitude but that seems completely illogical if that really is the case!
What good is this type if you cant put latitude and longitude data in it?!?!

For this reason, I’m asking to see if I’m missing something simple. Here is what I have to show this:

SELECT GEOMFROMTEXT('POLYGON((52.29600522644751 0.05256918782038156,52.29168750609503 0.04999426716608468,52.29425981571103 0.06121662968439523))');

Returns:

(NULL)

Whereas, if I create a point Geometry type:

SELECT GEOMFROMTEXT('POINT(52.29600522644751 0.05256918782038156)');

This returns a blank value which does actually contain the X and Y points.

Any help would be greatly appreciated.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T20:22:41+00:00Added an answer on June 1, 2026 at 8:22 pm

    GEOMFROMTEXT returns null if the geometry is invalid.
    The linear ring that you’re using to build your polygon is invalid. The ring start and termination points must be equal to complete the ring.

    A valid polygon in this case would be:

    SELECT GEOMFROMTEXT('POLYGON((52.29600522644751 0.05256918782038156,52.29168750609503 0.04999426716608468,52.29425981571103 0.06121662968439523,52.29600522644751 0.05256918782038156))')
    

    This returns the expected value instead of NULL.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have searched High and low for an answer to the following. I have
I have searched high and low for an answer to why query results returned
I am a newbie and have searched high and low for an answer to
I have searched high and low for an answer/tutorial on this with no joy.
I have searched high and low for an answer and have found similar examples
I have searched high and low looking for a simple class or set of
I have searched high and low for documentation on how to use this feature.
I have searched the knowledge base high and low, but nothing seems to give
I have searched high and low for an example of editing a parents children
I have searched high and low, but I can't figure this one out. I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.