[Geojson] Query

Bart van den Eijnden bartvde at osgis.nl
Thu Dec 13 07:32:08 PST 2012


Just use something like ogr2ogr to do that:

http://www.gdal.org/ogr/drv_geojson.html

Best regards,
Bart

-- 
Bart van den Eijnden
OSGIS - http://osgis.nl

On Dec 13, 2012, at 4:25 PM, Michael Ngugi Kimani <kimanimike2002 at yahoo.com> wrote:

> Thanks for the reply.
> 
> Using you example indicated below, is there a way of getting the values of the point i.e the Lat, Long without manually entering the values like 
> [100.0, 0.0] and so on. This is when am reading a shape file stored in postgis and it doesn't have a column for X and Y.
> 
>  
>  
>  
>  
> Respectfully yours,
>  
> ********************************************
>  
> Ngugi Kimani M.
> P.O. Box 449 - 00520
> Ruai, Kenya.
> Tel: +254-721324886
> Email: kimanimike2002 at yahoo.com
>  
> ********************************************
> 
> From: Matt Priour <mpriour at kestrelcomputer.com>
> To: geojson at lists.geojson.org 
> Sent: Thursday, December 13, 2012 6:16 PM
> Subject: Re: [Geojson] Query
> 
> I'm not sure I understand your question.
> Your example is a polygon, not a point. A point is represented like this:
> 
> { "type": "Point", "coordinates": [100.0, 0.0] }
> 
> or a feature collection of points:
> 
> { "type": "FeatureCollection",
>   "features": [
>     { "type": "Feature1",
>       "geometry": { "type": "Point", "coordinates": [100.0, 0.0] },
>       "properties": {"prop0": "value0"}
>       },
> { "type": "Feature2",
>       "geometry": { "type": "Point", "coordinates": [90.0, 60.0] },
>       "properties": {"prop0": "value1", "foo":"bar"}
>       }]
> }
> 
> 
> Matt Priour
> 
> 
> 
> 
> 
> On 12/13/2012 7:23 AM, Michael Ngugi Kimani wrote:
>> 
>>  
>> Hallo all,
>> 
>> Using the example below of displaying  point is there a way of reading the coordinates automatically since getting the coordinates of several polygon might be alot of work.
>> 
>> 
>> { "type": "FeatureCollection",
>>   "features": [
>>     { "type": "Feature",
>>       "geometry": {"type": "Polygon", "coordinates": [ [100.0, 0.0], [101.0, 0.0], [101.0, 1.0],
>>              [100.0, 1.0], [100.0, 0.0] ]
>>            ]},
>>       "properties": {"prop0": "value0"}
>>       }]
>> }
>> 
>>  
>>  
>>  
>> Respectfully yours,
>>  
>> ********************************************
>>  
>> Ngugi Kimani M.
>> P.O. Box 449 - 00520
>> Ruai, Kenya.
>> Tel: +254-721324886
>> Email: kimanimike2002 at yahoo.com
>>  
>> ********************************************
>> 
>> 
>> _______________________________________________
>> Geojson mailing list
>> Geojson at lists.geojson.org
>> http://lists.geojson.org/listinfo.cgi/geojson-geojson.org
> 
> 
> _______________________________________________
> Geojson mailing list
> Geojson at lists.geojson.org
> http://lists.geojson.org/listinfo.cgi/geojson-geojson.org
> 
> 
> _______________________________________________
> Geojson mailing list
> Geojson at lists.geojson.org
> http://lists.geojson.org/listinfo.cgi/geojson-geojson.org

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.geojson.org/pipermail/geojson-geojson.org/attachments/20121213/f90ef23e/attachment.htm>


More information about the GeoJSON mailing list