<div dir="ltr">thanks Bo victor <span style="font-family:arial,sans-serif;font-size:13px">Thomsen</span><div><br></div><div>I have tried this query and was able to add different types of geometries into my postgis</div><div>
however the geometry column of every tables reads as wkb_geometry geometry(MultiLineString,900914),</div><div><br></div><div>can anyone explain to me that what does this means, a normal geometry table only has only this argument wkb_geometry geometry,</div>
<div><br></div><div><br></div><div>best</div><div>Ibad Raza</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Sep 5, 2013 at 2:49 AM, Bo Victor Thomsen <span dir="ltr"><<a href="mailto:bo.victor.thomsen@gmail.com" target="_blank">bo.victor.thomsen@gmail.com</a>></span> wrote:<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>Ibad -<br>
      <br>
      The problem is that MapInfo tab files can contain several types of
      geometry object all mixed together - lines, polygons, points ...
      in a single file. This is not allowed in Postgis tables used by
      QGIS.<br>
      You have to split your "multi-type" tab file into several postgis
      tables, where each table only contains one type of geoobject<br>
      <br>
      Try the following on a command line (in windows):<br>
       <br>
      <b>for %a in (multilinestring multipolygon linestring polygon
        point multipoint none) do ogr2ogr -where "OGR_GEOMETRY='%a'" -f
        "PostgreSQL" PG:"host=</b><b><i>myserver</i></b><b><i></i></b><b>
        user=</b><b><i>myuser</i></b><b><i></i></b><b> dbname=</b><b><i>mydatabase</i></b><b><i></i></b><b>
        password=</b><b><i>mypassword</i></b><b><i></i></b><b>" -nlt %a
        -nln </b><b><i>tablename</i></b><b><i></i></b><b>_%a </b><b><i>mytabfile.tab</i></b><br>
      <br>
      - Replace italic text as needed<br>
      - If the commandline is put into a .cmd file: Replace every
      occurence of %a with %%a<br>
       <br>
      The command will create 7 new layers for each tabfile. Each new
      table will only contain one type of object (Depending on the
      contents of the tabfile, some or most of the tables will be empty)
      <br>
      <br>
      Regards<br>
      Bo Victor Thomsen<br>
      Aestas-GIS<br>
      Denmark<br>
      <br>
      <br>
      Den 04-09-2013 21:03, ibad raza skrev:<br>
    </div>
    <blockquote type="cite"><div><div class="h5">
      <div dir="ltr">hello list
        <div><br>
        </div>
        <div>I am trying to add a mapinfo file to postgis</div>
        <div>I have tried the fwtool ogr2ogr function</div>
        <div>but the problem is that everytime I add the file, some
          records are missing</div>
        <div>these are the records with no geometry which do not get
          added in the final table</div>
        <div><br>
        </div>
        <div><br>
        </div>
        <div>can anyone tell me that firstlly how can I add the rows
          without geometry in the table as well.</div>
        <div><br>
        </div>
        <div>and is there another easy way to get mapinfo file into
          postgis</div>
        <div><br>
        </div>
        <div>Thanks</div>
        <div>Ibad Raza</div>
      </div>
      <br>
      <fieldset></fieldset>
      <br>
      </div></div><pre>_______________________________________________
Qgis-user mailing list
<a href="mailto:Qgis-user@lists.osgeo.org" target="_blank">Qgis-user@lists.osgeo.org</a>
<a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-user</a></pre>
    </blockquote>
    <br>
  </div>

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