Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Why Geo.PostGIS.Geometry? #230

Open
leifmetcalf opened this issue Jan 21, 2025 · 0 comments
Open

Why Geo.PostGIS.Geometry? #230

leifmetcalf opened this issue Jan 21, 2025 · 0 comments

Comments

@leifmetcalf
Copy link

leifmetcalf commented Jan 21, 2025

I'm curious why you chose to have only the generic Geometry Ecto.Type implementation and not separate implementations for Point, Polygon, etc. For example:

schema "restaurants" do
  field :name, :string
  field :address, :string
  field :location, Geo.Point

  timestamps(type: :utc_datetime)
end

Wouldn't it be useful to know that the coordinate is a point?

@leifmetcalf leifmetcalf changed the title Why Geo.PostGIS.Geometry? Why Geo.PostGIS.Geometry? Jan 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant