[prev in list] [next in list] [prev in thread] [next in thread] 

List:       postgis-users
Subject:    [postgis-users] Re: Problem loading shape data (Paul Ramsey)
From:       "John Zhang" <johnzhang06 () gmail ! com>
Date:       2008-12-16 22:51:13
Message-ID: 618950b80812161451g222e5a53hf206f977e36f529c () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


Thank you, Paul. The encoding does make it work better. However, only half
the data transferred. (raw data with 518 rows, new with 269 rows ). Without
-W LATIN1 option, only 11 rows got transferred. Any other options?

Thanks a lot.
John

Subject: Re: [postgis-users] Re: Problem loading shape data (Paul
       Ramsey)
To: "PostGIS Users Discussion" <postgis-users@postgis.refractions.net>
Message-ID:
       <30fe546d0812151227p48de9c10qfdce3694145c3d09@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1

Try adding -W LATIN1 to your shp2pgsql invocation. You have some
(garbage?) hibit characters in your file.

P

On Mon, Dec 15, 2008 at 12:14 PM, John Zhang <johnzhang06@gmail.com> wrote:
> oops............here are the attachments
>
> On Mon, Dec 15, 2008 at 9:58 AM, John Zhang <johnzhang06@gmail.com> wrote:
>>
>>  Hi Paul,
>>
>> Thank you very much for the input and the hint on how to get the whole
>> error message.
>> Attached are the error message file and the generated script file for
your
>> reference.
>>
>> The commands used are:
>>
>> shp2pgsql -s 3005 "..\AbaloneClosures.shp" hm_vect.AbaloneClosures2 >
>> D:\tmp\AbaloneClosures2.sql
>> psql -h flash.HaidaMapping.local -d hm -U  postgres -f
>> D:\tmp\AbaloneClosures2.sql
>>
>> Based on the error message, the table "hm_vect"."abaloneclosures2" seemed
>> created. However, it is not.
>>
>> Your input on the problem would be much appreciated!
>>
>> Thanks
>> John
>>
>>> Date: Sat, 13 Dec 2008 16:36:00 -0800
>>> From: "Paul Ramsey" <pramsey@cleverelephant.ca>
>>> Subject: Re: [postgis-users] Problem loading shape data
>>> To: "PostGIS Users Discussion" <postgis-users@postgis.refractions.net>
>>> Message-ID:
>>>        <30fe546d0812131636v212853d8wa3422f29f4e142fc@mail.gmail.com>
>>> Content-Type: text/plain; charset=ISO-8859-1
>>>
>>> You have to scroll up in the window until you can see what the
>>> *actual* error is... increase your command terminal scroll buffers to
>>> 5000 then re-run and scroll up to the first error message.
>>>
>>> On Fri, Dec 12, 2008 at 3:17 PM, John Zhang <johnzhang06@gmail.com>
>>> wrote:
>>> >  Hi there,
>>> >
>>> > I used shp2pgsql command to convert shape data to postgis. I met a
>>> > problem
>>> > when I tried to run the generated sql data file.
>>> >
>>> > The command is as follows:
>>> >
>>> > shp2pgsql -s 3005 "..\AbaloneClosures.shp" hm_vect.AbaloneClosures >
>>> > D:\tmp\AbaloneClosures.sql | psql -h flash.HaidaMapping.local -d hm -U
>>> > postgres -f D:\tmp\AbaloneClosures.sql
>>> >
>>> > the message tells: "..current transaction is aborted..". However, when
>>> > I
>>> > copied the command to a query window to run, it was successful. It is
a
>>> > polygon feature class with less than 1000 rows.
>>> >
>>> > When I ran
>>> > psql -h flash.HaidaMapping.local -d hm -U postgres -f
>>> > D:\tmp\AbaloneClosures.sql
>>> > the same problem occurred.
>>> >
>>> > Any input would be appreciated.
>>> >
>>> > Thanks a lot
>>> > John

[Attachment #5 (text/html)]

Thank you, Paul. The encoding does make it work better. However, only half the data \
transferred. (raw data with 518 rows, new with 269 rows ). Without -W LATIN1 option, \
only 11 rows got transferred. Any other options?<br><br> Thanks a \
lot.<br>John<br>&nbsp;<br>Subject: Re: [postgis-users] Re: Problem loading shape data \
(Paul<br>  &nbsp; &nbsp; &nbsp; &nbsp;Ramsey)<br>
To: &quot;PostGIS Users Discussion&quot; &lt;<a \
href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</a>&gt;<br>
 Message-ID:<br>
 &nbsp; &nbsp; &nbsp; &nbsp;&lt;<a \
href="mailto:30fe546d0812151227p48de9c10qfdce3694145c3d09@mail.gmail.com">30fe546d0812151227p48de9c10qfdce3694145c3d09@mail.gmail.com</a><div \
                id=":vc" class="ArwC7c ckChnd">&gt;<br>
Content-Type: text/plain; charset=ISO-8859-1<br>
<br>
Try adding -W LATIN1 to your shp2pgsql invocation. You have some<br>
(garbage?) hibit characters in your file.<br>
<br>
P<br>
<br>
On Mon, Dec 15, 2008 at 12:14 PM, John Zhang &lt;<a \
href="mailto:johnzhang06@gmail.com">johnzhang06@gmail.com</a>&gt; wrote:<br> &gt; \
oops............here are the attachments<br> &gt;<br>
&gt; On Mon, Dec 15, 2008 at 9:58 AM, John Zhang &lt;<a \
href="mailto:johnzhang06@gmail.com">johnzhang06@gmail.com</a>&gt; wrote:<br> \
&gt;&gt;<br> &gt;&gt; &nbsp;Hi Paul,<br>
&gt;&gt;<br>
&gt;&gt; Thank you very much for the input and the hint on how to get the whole<br>
&gt;&gt; error message.<br>
&gt;&gt; Attached are the error message file and the generated script file for \
your<br> &gt;&gt; reference.<br>
&gt;&gt;<br>
&gt;&gt; The commands used are:<br>
&gt;&gt;<br>
&gt;&gt; shp2pgsql -s 3005 &quot;..\AbaloneClosures.shp&quot; \
hm_vect.AbaloneClosures2 &gt;<br> &gt;&gt; D:\tmp\AbaloneClosures2.sql<br>
&gt;&gt; psql -h flash.HaidaMapping.local -d hm -U &nbsp;postgres -f<br>
&gt;&gt; D:\tmp\AbaloneClosures2.sql<br>
&gt;&gt;<br>
&gt;&gt; Based on the error message, the table \
&quot;hm_vect&quot;.&quot;abaloneclosures2&quot; seemed<br> &gt;&gt; created. \
However, it is not.<br> &gt;&gt;<br>
&gt;&gt; Your input on the problem would be much appreciated!<br>
&gt;&gt;<br>
&gt;&gt; Thanks<br>
&gt;&gt; John<br>
&gt;&gt;<br>
&gt;&gt;&gt; Date: Sat, 13 Dec 2008 16:36:00 -0800<br>
&gt;&gt;&gt; From: &quot;Paul Ramsey&quot; &lt;<a \
href="mailto:pramsey@cleverelephant.ca">pramsey@cleverelephant.ca</a>&gt;<br> \
&gt;&gt;&gt; Subject: Re: [postgis-users] Problem loading shape data<br> &gt;&gt;&gt; \
To: &quot;PostGIS Users Discussion&quot; &lt;<a \
href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</a>&gt;<br>
 &gt;&gt;&gt; Message-ID:<br>
&gt;&gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp;&lt;<a \
href="mailto:30fe546d0812131636v212853d8wa3422f29f4e142fc@mail.gmail.com">30fe546d0812131636v212853d8wa3422f29f4e142fc@mail.gmail.com</a>&gt;<br>
 &gt;&gt;&gt; Content-Type: text/plain; charset=ISO-8859-1<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; You have to scroll up in the window until you can see what the<br>
&gt;&gt;&gt; *actual* error is... increase your command terminal scroll buffers \
to<br> &gt;&gt;&gt; 5000 then re-run and scroll up to the first error message.<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; On Fri, Dec 12, 2008 at 3:17 PM, John Zhang &lt;<a \
href="mailto:johnzhang06@gmail.com">johnzhang06@gmail.com</a>&gt;<br> &gt;&gt;&gt; \
wrote:<br> &gt;&gt;&gt; &gt; &nbsp;Hi there,<br>
&gt;&gt;&gt; &gt;<br>
&gt;&gt;&gt; &gt; I used shp2pgsql command to convert shape data to postgis. I met \
a<br> &gt;&gt;&gt; &gt; problem<br>
&gt;&gt;&gt; &gt; when I tried to run the generated sql data file.<br>
&gt;&gt;&gt; &gt;<br>
&gt;&gt;&gt; &gt; The command is as follows:<br>
&gt;&gt;&gt; &gt;<br>
&gt;&gt;&gt; &gt; shp2pgsql -s 3005 &quot;..\AbaloneClosures.shp&quot; \
hm_vect.AbaloneClosures &gt;<br> &gt;&gt;&gt; &gt; D:\tmp\AbaloneClosures.sql | psql \
-h flash.HaidaMapping.local -d hm -U<br> &gt;&gt;&gt; &gt; postgres -f \
D:\tmp\AbaloneClosures.sql<br> &gt;&gt;&gt; &gt;<br>
&gt;&gt;&gt; &gt; the message tells: &quot;..current transaction is aborted..&quot;. \
However, when<br> &gt;&gt;&gt; &gt; I<br>
&gt;&gt;&gt; &gt; copied the command to a query window to run, it was successful. It \
is a<br> &gt;&gt;&gt; &gt; polygon feature class with less than 1000 rows.<br>
&gt;&gt;&gt; &gt;<br>
&gt;&gt;&gt; &gt; When I ran<br>
&gt;&gt;&gt; &gt; psql -h flash.HaidaMapping.local -d hm -U postgres -f<br>
&gt;&gt;&gt; &gt; D:\tmp\AbaloneClosures.sql<br>
&gt;&gt;&gt; &gt; the same problem occurred.<br>
&gt;&gt;&gt; &gt;<br>
&gt;&gt;&gt; &gt; Any input would be appreciated.<br>
&gt;&gt;&gt; &gt;<br>
&gt;&gt;&gt; &gt; Thanks a lot<br>
&gt;&gt;&gt; &gt; John</div><br>



_______________________________________________
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic