<div dir="ltr">Hi:<div><br></div><div>Thanks for your reply.</div><div><br></div><div>But I wonder how do I know if the file name is utf8? Since not all of the filename contain no-asci characters.</div><div><br></div><div>

Thanks</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">2014/1/8 Dmitriy Baryshnikov <span dir="ltr"><<a href="mailto:bishop.dev@gmail.com" target="_blank">bishop.dev@gmail.com</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


  
    
  
  <div text="#000000" bgcolor="#FFFFFF">
    <div>Hi,<br>
      <br>
      The GDAL utilities expected all input paths in UTF-8 encoding. If
      you want to use system native encoding you have to set
      GDAL_FILENAME_IS_UTF8 environment variable to NO.<br>
      <a href="http://trac.osgeo.org/gdal/wiki/ConfigOptions#GDAL_FILENAME_IS_UTF8" target="_blank">http://trac.osgeo.org/gdal/wiki/ConfigOptions#GDAL_FILENAME_IS_UTF8</a><br>
      <pre cols="72">Best regards,
    Dmitry</pre>
      08.01.2014 4:03, maven apache пишет:<br>
    </div>
    <blockquote type="cite"><div><div class="h5">
      <div dir="ltr">Hi:
        <div><br>
        </div>
        <div>This is a cross post first post at <a href="http://gis.stackexchange.com/questions/82142/ogr2ogr-does-not-support-file-name-with-non-ascii-character" target="_blank">http://gis.stackexchange.com/questions/82142/ogr2ogr-does-not-support-file-name-with-non-ascii-character</a></div>


        <div><br>
        </div>
        <div>Since I got no answer, then I think I may post it here,
          this is the original question:</div>
        <div><br>
        </div>
        <div>
          <p>
            I tried to use the following script to convert shapefile to
            mif:</p>
          <pre style="margin-top:0px;margin-bottom:10px;padding:5px;border:0px;font-size:12px;vertical-align:baseline;overflow:auto;width:auto;max-height:600px;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,serif;background-color:rgb(238,238,238);word-wrap:normal;color:rgb(51,51,51);line-height:18px">

<code style="margin:0px;padding:0px;border:0px;vertical-align:baseline;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,serif;color:rgb(34,34,34)">ogr2ogr -f "MapInfo File" D:\docs\arcgis_data\shp_mif\BOU.mif D:\docs\arcgis_data\shp\BOU.shp
</code></pre>
          <p>
            it works.</p>
          <p>
            But I found that if the name of the shapefile has non-ASCII
            characters like this:</p>
          <pre style="margin-top:0px;margin-bottom:10px;padding:5px;border:0px;font-size:12px;vertical-align:baseline;overflow:auto;width:auto;max-height:600px;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,serif;background-color:rgb(238,238,238);word-wrap:normal;color:rgb(51,51,51);line-height:18px">

<code style="margin:0px;padding:0px;border:0px;vertical-align:baseline;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,serif;color:rgb(34,34,34)">D:\docs\arcgis_data\shp\臺北.shp
</code></pre>
          <p>
            Then the covert will fail with message:</p>
          <pre style="margin-top:0px;margin-bottom:10px;padding:5px;border:0px;font-size:12px;vertical-align:baseline;overflow:auto;width:auto;max-height:600px;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,serif;background-color:rgb(238,238,238);word-wrap:normal;color:rgb(51,51,51);line-height:18px">

<code style="margin:0px;padding:0px;border:0px;vertical-align:baseline;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,serif;color:rgb(34,34,34)">Unable to open datasource `D:\docs\arcgis_data\shp\臺北.shp' with the following drivers
......
</code></pre>
          <p>
            Any idea to fix it?</p>
          <p>
            Looking for replay.</p>
          <p>
            <br>
          </p>
          <p>
            Yang</p>
          <p>
            2014.1.8</p>
        </div>
      </div>
      <br>
      <fieldset></fieldset>
      <br>
      </div></div><pre>_______________________________________________
gdal-dev mailing list
<a href="mailto:gdal-dev@lists.osgeo.org" target="_blank">gdal-dev@lists.osgeo.org</a>
<a href="http://lists.osgeo.org/mailman/listinfo/gdal-dev" target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a></pre>
    </blockquote>
    <br>
  </div>

<br>_______________________________________________<br>
gdal-dev mailing list<br>
<a href="mailto:gdal-dev@lists.osgeo.org">gdal-dev@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/gdal-dev" target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br></blockquote></div><br></div>