[postgis-users] - The greater length River inside one Watershed
George Silva
georger.silva at gmail.com
Tue Apr 26 05:23:42 PDT 2011
ooops, prior to max use st_length!
On 4/26/11, George Silva <georger.silva at gmail.com> wrote:
> hello marcello. what is your data model? dependng on the data model
> (if you have a column, lets say, rivername) you can use a group by
> clause and st_collect on your geometry field. ex:
>
> select rivername, max(st_collect(the_geom)) from rivers group by rivername
>
> the intersects clause its up to you , depending on your néds. not
> tested, but should work.
>
> On 4/26/11, Marcello Benigno <benigno.marcello at gmail.com> wrote:
>> Hi All,
>>
>> I need a query that returns the greater length of river within a
>> watershed. Does
>> anyone have any suggestions on how I can solve this problem?
>>
>> The rivers are formed by segments. if each were a continuous line would
>> be
>> easy.
>>
>> Here is a print-screen of the problem, in yellow is what would be the
>> result
>> of
>> the query.
>>
>> Thanks in advance,
>> --
>> *Marcello Benigno B. de Barros Filho*
>> Prof. do Curso Superior de Tecnologia em Geoprocessamento - IFPB
>> Mestre em Ciências Geodésicas e Tecnologias da Geoinformação - UFPE
>> http://profmarcello.blogspot.com
>> http://about.me/marcello.benigno
>>
>
>
> --
> George R. C. Silva
>
> Desenvolvimento em GIS
> http://geoprocessamento.net
> http://blog.geoprocessamento.net
>
--
George R. C. Silva
Desenvolvimento em GIS
http://geoprocessamento.net
http://blog.geoprocessamento.net
More information about the postgis-users
mailing list