<html>
  <head>
    <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">I really like the RFC31! <br>
      Also it'll be great to have a chocie to build GDAL with internal
      and external json-c, as libtif, libjpeg, etc. are. And drop
      patched version of json-c.<br>
      <pre class="moz-signature" cols="72">Best regards,
    Dmitriy</pre>
      02.08.2013 0:36, Frank Warmerdam пишет:<br>
    </div>
    <blockquote
cite="mid:CA+YzLBc5RVxk_JgkruxCGP7MsaY7a5Sg9Kv249y5Yp5-O8G1YA@mail.gmail.com"
      type="cite">
      <div dir="ltr"><br>
        <div class="gmail_extra"><br>
          <br>
          <div class="gmail_quote">On Thu, Aug 1, 2013 at 1:32 PM, Even
            Rouault <span dir="ltr"><<a moz-do-not-send="true"
                href="mailto:even.rouault@mines-paris.org"
                target="_blank">even.rouault@mines-paris.org</a>></span>
            wrote:<br>
            <blockquote class="gmail_quote" style="margin:0 0 0
              .8ex;border-left:1px #ccc solid;padding-left:1ex">Selon
              Dmitriy Baryshnikov <<a moz-do-not-send="true"
                href="mailto:bishop.dev@gmail.com">bishop.dev@gmail.com</a>>:<br>
              <div class="im"><br>
                > Hi,<br>
                ><br>
                > GDAL GeoJSON driver use modified and outdated
                json-c. It seem to me that<br>
                > this is the bug and ticket in track needed.<br>
                <br>
              </div>
              It would be a 2 step work. I indeed see that newer json-c
              supports int64, so a<br>
              first step would be to make the GeoJSON driver uses the
              new json-c 64 bit API.<br>
              But OGR does not support int64 yet, so the overflow would
              occur just afterwards.<br>
              There's an RFC ( <a moz-do-not-send="true"
                href="http://trac.osgeo.org/gdal/wiki/rfc31_ogr_64"
                target="_blank">http://trac.osgeo.org/gdal/wiki/rfc31_ogr_64</a>
              ) about that<br>
              waiting for implementation.<br>
            </blockquote>
            <div><br>
            </div>
            <div>Folks,</div>
            <div><br>
            </div>
            <div>Also waiting for final refinement and adoption...</div>
            <div><br>
            </div>
            <div>I think I'd like to revisit this issue before the next
              major release since it is negatively impacting a number of
              drivers - not just geojson.</div>
            <div><br>
            </div>
            <div>Best regards,<br>
            </div>
            <div>Frank</div>
            <div> </div>
            <blockquote class="gmail_quote" style="margin:0 0 0
              .8ex;border-left:1px #ccc solid;padding-left:1ex">
              <br>
              Best regards,<br>
              <br>
              Even<br>
              <br>
              ><br>
              > Best regards,<br>
              >      Dmitriy<br>
              ><br>
              > 01.08.2013 22:31, Smith, Michael ERDC-RDE-CRREL-NH
              Ð¿ÐžÑ ÐµÑ :<br>
              > > Unfortunately, that¹s after the data has been
              read and overflowed.<br>
              <div class="HOEnZb">
                <div class="h5">> ><br>
                  > > The time should be 1375291903959.<br>
                  > > Updated should be 1375295733317.<br>
                  > ><br>
                  > > Mike<br>
                  > ><br>
                  > > On 8/1/13 2:21 PM, "Kyle Shannon" <<a
                    moz-do-not-send="true" href="mailto:kyle@pobox.com">kyle@pobox.com</a>>
                  wrote:<br>
                  > ><br>
                  > >> On Thu, Aug 1, 2013 at 11:36 AM, Smith,
                  Michael ERDC-RDE-CRREL-NH<br>
                  > >> <<a moz-do-not-send="true"
                    href="mailto:Michael.Smith@erdc.dren.mil">Michael.Smith@erdc.dren.mil</a>>
                  wrote:<br>
                  > >>> I'm reading a geojson feed put out
                  by the USGS<br>
                  > >>><br>
                  > >>> (<a moz-do-not-send="true"
href="http://earthquake.usgs.gov/earthquakes/feed/v1.0/summary/all_day.geojson"
                    target="_blank">http://earthquake.usgs.gov/earthquakes/feed/v1.0/summary/all_day.geojson</a><br>
                  > >>> )<br>
                  > >>> but the time/updated values are
                  overflowing. Are there any settings to<br>
                  > >>> allow<br>
                  > >>> the data to come across as bigint or
                  strings?<br>
                  > >>><br>
                  > >>> For example:<br>
                  > >>>
                  {"type":"Feature","properties":{"mag":0.46,"place":"2km
                  W of Lemmon<br>
                  > >>> Valley,<br>
                  > >>><br>
                  > >>>
Nevada","time":1375291903959,"updated":1375295733317,"tz":-420,"url":"htt<br>
                  > >>> p://<a moz-do-not-send="true"
                    href="http://earthquake.usgs.gov/earthquakes/eventpage/nn00419191"
                    target="_blank">earthquake.usgs.gov/earthquakes/eventpage/nn00419191</a>","detail":"http:<br>
                  > >>> //<a moz-do-not-send="true"
href="http://earthquake.usgs.gov/earthquakes/feed/v1.0/detail/nn00419191.geojson"
                    target="_blank">earthquake.usgs.gov/earthquakes/feed/v1.0/detail/nn00419191.geojson</a>","f<br>
                  > >>>
elt":null,"cdi":null,"mmi":null,"alert":null,"status":"REVIEWED","tsunami<br>
                  > >>>
":null,"sig":3,"net":"nn","code":"00419191","ids":",nn00419191,","sources<br>
                  > >>>
":",nn,","types":",cap,general-link,geoserve,nearby-cities,origin,","nst"<br>
                  > >>>
:12,"dmin":0.069,"rms":0.1034,"gap":74,"magType":"ml","type":"earthquake"<br>
                  > >>>
},"geometry":{"type":"Point","coordinates":[-119.8773,39.632,5.0829]},"id<br>
                  > >>> ":"nn00419191"}<br>
                  > >>><br>
                  > >>> Gets returned as<br>
                  > >>><br>
                  > >>> OGRFeature(OGRGeoJSON):176<br>
                  > >>>    mag (Real) = 1.7<br>
                  > >>>    place (String) = 21km S of
                  Lowell, Oregon<br>
                  > >>>    time (Integer) = 902732480<br>
                  > >>>    updated (Integer) = 903846662<br>
                  > >>>    tz (Integer) = -420<br>
                  > >>>    url (String) =<br>
                  > >>> <a moz-do-not-send="true"
                    href="http://earthquake.usgs.gov/earthquakes/eventpage/uw60561592"
                    target="_blank">http://earthquake.usgs.gov/earthquakes/eventpage/uw60561592</a><br>
                  > >>>    detail (String) =<br>
                  > >>><br>
                  > >>> <a moz-do-not-send="true"
href="http://earthquake.usgs.gov/earthquakes/feed/v1.0/detail/uw60561592.geojso"
                    target="_blank">http://earthquake.usgs.gov/earthquakes/feed/v1.0/detail/uw60561592.geojso</a><br>
                  > >>> n<br>
                  > >>>    felt (String) = (null)<br>
                  > >>>    cdi (String) = (null)<br>
                  > >>>    mmi (String) = (null)<br>
                  > >>>    alert (String) = (null)<br>
                  > >>>    status (String) = REVIEWED<br>
                  > >>>    tsunami (String) = (null)<br>
                  > >>>    sig (Integer) = 44<br>
                  > >>>    net (String) = uw<br>
                  > >>>    code (String) = 60561592<br>
                  > >>>    ids (String) = ,uw60561592,<br>
                  > >>>    sources (String) = ,uw,<br>
                  > >>>    types (String) =
                  ,cap,general-link,geoserve,nearby-cities,origin,<br>
                  > >>>    nst (Integer) = (null)<br>
                  > >>>    dmin (Real) = 0.24254513<br>
                  > >>>    rms (Real) = 0.24<br>
                  > >>>    gap (Real) = 118.8<br>
                  > >>>    magType (String) = Md<br>
                  > >>>    type (String) = quarry<br>
                  > >>>    POINT (-122.7927 43.7262 0)<br>
                  > >>><br>
                  > >>>
                  _______________________________________________<br>
                  > >>> gdal-dev mailing list<br>
                  > >>> <a moz-do-not-send="true"
                    href="mailto:gdal-dev@lists.osgeo.org">gdal-dev@lists.osgeo.org</a><br>
                  > >>> <a moz-do-not-send="true"
                    href="http://lists.osgeo.org/mailman/listinfo/gdal-dev"
                    target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br>
                  > >> Try the cast operator in ogr sql:<br>
                  > >><br>
                  > >> kyle@kyle-workstation:~$ ogrinfo -sql
                  'select *, cast(time as<br>
                  > >> character(0)),cast(updated as
                  character(0)) from OGRGeoJSON'<br>
                  > >> /vsicurl/<a moz-do-not-send="true"
                    href="http://earthquake.usgs.gov/earthquakes/feed/v1.0/summary/all_day"
                    target="_blank">http://earthquake.usgs.gov/earthquakes/feed/v1.0/summary/all_day</a>.<br>
                  > >> geojson<br>
                  > >><br>
                  > >> ...<br>
                  > >><br>
                  > >><br>
                  > >> OGRFeature(OGRGeoJSON):185<br>
                  > >>   mag (Real) = 2.4<br>
                  > >>   place (String) = 29km N of Brenas,
                  Puerto Rico<br>
                  > >>   time (Integer) = 905049680<br>
                  > >>   updated (Integer) = 908474945<br>
                  > >>   tz (Integer) = -240<br>
                  > >>   url (String) =<br>
                  > >> <a moz-do-not-send="true"
                    href="http://earthquake.usgs.gov/earthquakes/eventpage/pr13212004"
                    target="_blank">http://earthquake.usgs.gov/earthquakes/eventpage/pr13212004</a><br>
                  > >>   detail (String) =<br>
                  > >> <a moz-do-not-send="true"
href="http://earthquake.usgs.gov/earthquakes/feed/v1.0/detail/pr13212004.geojson"
                    target="_blank">http://earthquake.usgs.gov/earthquakes/feed/v1.0/detail/pr13212004.geojson</a><br>
                  > >>   felt (String) = (null)<br>
                  > >>   cdi (String) = (null)<br>
                  > >>   mmi (String) = (null)<br>
                  > >>   alert (String) = (null)<br>
                  > >>   status (String) = REVIEWED<br>
                  > >>   tsunami (String) = (null)<br>
                  > >>   sig (Integer) = 89<br>
                  > >>   net (String) = pr<br>
                  > >>   code (String) = 13212004<br>
                  > >>   ids (String) = ,pr13212004,<br>
                  > >>   sources (String) = ,pr,<br>
                  > >>   types (String) =
                  ,cap,geoserve,nearby-cities,origin,tectonic-summary,<br>
                  > >>   nst (String) = 13<br>
                  > >>   dmin (Real) = 0.30722383<br>
                  > >>   rms (Real) = 0.27<br>
                  > >>   gap (Real) = 219.6<br>
                  > >>   magType (String) = Md<br>
                  > >>   type (String) = earthquake<br>
                  > >>   time (String) = 905049680<br>
                  > >>   updated (String) = 908474945<br>
                  > >>   POINT (-66.3495 18.7346 29)<br>
                  > >><br>
                  > >> note the values at the bottom, time and
                  update as (String).  You could<br>
                  > >> write the entire field list in  the sql
                  and substitue time and updated<br>
                  > >> for the casted values.<br>
                  > >><br>
                  > >> kss<br>
                  > >
                  _______________________________________________<br>
                  > > gdal-dev mailing list<br>
                  > > <a moz-do-not-send="true"
                    href="mailto:gdal-dev@lists.osgeo.org">gdal-dev@lists.osgeo.org</a><br>
                  > > <a moz-do-not-send="true"
                    href="http://lists.osgeo.org/mailman/listinfo/gdal-dev"
                    target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br>
                  > ><br>
                  > ><br>
                  ><br>
                  > _______________________________________________<br>
                  > gdal-dev mailing list<br>
                  > <a moz-do-not-send="true"
                    href="mailto:gdal-dev@lists.osgeo.org">gdal-dev@lists.osgeo.org</a><br>
                  > <a moz-do-not-send="true"
                    href="http://lists.osgeo.org/mailman/listinfo/gdal-dev"
                    target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br>
                  <br>
                  <br>
                  _______________________________________________<br>
                  gdal-dev mailing list<br>
                  <a moz-do-not-send="true"
                    href="mailto:gdal-dev@lists.osgeo.org">gdal-dev@lists.osgeo.org</a><br>
                  <a moz-do-not-send="true"
                    href="http://lists.osgeo.org/mailman/listinfo/gdal-dev"
                    target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br>
                </div>
              </div>
            </blockquote>
          </div>
          <br>
          <br clear="all">
          <div><br>
          </div>
          -- <br>
---------------------------------------+--------------------------------------<br>
          I set the clouds in motion - turn up   | Frank Warmerdam, <a
            moz-do-not-send="true" href="mailto:warmerdam@pobox.com"
            target="_blank">warmerdam@pobox.com</a><br>
          light and sound - activate the windows | <a
            moz-do-not-send="true" href="http://pobox.com/%7Ewarmerdam"
            target="_blank">http://pobox.com/~warmerdam</a><br>
          and watch the world go round - Rush    | Geospatial Software
          Developer<br>
        </div>
      </div>
    </blockquote>
    <br>
  </body>
</html>