Re: How to create a View of geometry type equals point?

From: Sándor Daku <daku(dot)sandor(at)gmail(dot)com>
To: Nicholas G Lawrence <nicholas(dot)g(dot)lawrence(at)tmr(dot)qld(dot)gov(dot)au>
Cc: pgsql-novice(at)lists(dot)postgresql(dot)org
Subject: Re: How to create a View of geometry type equals point?
Date: 2024-06-14 04:36:26
Message-ID: CAKyoTgYyrrDCUL=G5DoiWByS9cO3uCBVHZa6CvotwYhvHq_BVQ@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Hello Nicholas,

> I want to create a View within PostGIS that filters only those records
> that have Geometry type equal to Point
>
> (and also another view of geometry type equal to Polygon)
>
> What SELECT statement achieves this?
>

I'm not familiar with PostGIS, but based on a quick glance at the docs I
think the ST_Dimension function is what you need. Something like: ...where
ST_Dimension(geometry_field) = 0

Regards,

Sándor

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message Roxanne Reid-Bennett 2024-06-14 06:38:13 Re: How to create a View of geometry type equals point?
Previous Message Nicholas G Lawrence 2024-06-14 03:50:31 How to create a View of geometry type equals point?