[postgis-users] Loading data
Dylan Keon
dbkeon.ml at gmail.com
Fri Apr 1 22:33:52 PST 2005
On 04/01/2005 09:51 PM Robert Aldridge wrote the following:
> Hello list,
>
> I'm attempting to load two (rural) counties' TIGER
> roads into PostGIS using
>
> shp2pgsql county_1_roads myschema.roads > roads_1.sql
> shp2pgsql county_2_roads myschema.roads > roads_2.sql
>
> I combined roads_1.sql and roads_2.sql being careful
> to change the last line in the resulting file to:
>
> SELECT setval ('myschema.roads_gid_seq', 17033, true);
>
> where 17033 is the sum of the values in this line in
> roads_1.sql and roads_2.sql.
>
> I keep getting the error:
>
> ERROR: syntax error at or near "." at character
> 7608823
>
> Is there a tool (in Linux) that I can use to find the
> LINE in the SQL file where character 7608823 occurs?
> I normally use Vim to edit text files, but if you can
> go to a specific character based on count with Vim,
> it's beyond my Vim knowledge (which wouldn't suprise
> me).
To answer your vim question - one way to do it is to type 'g' then
'ctrl-g' in vim. This will give you the byte count at the cursor
position, among other things.
--Dylan
More information about the postgis-users
mailing list