[postgis-users] "Field xx renamed to XX_01"
Stefan Schwarzer
stefan.schwarzer at grid.unep.ch
Mon Jan 22 00:07:29 PST 2007
Yes, I dumped other tables and that was ok. It seems there are only a
couple of tables out of the 500 or so we have that does it... I
couldn't figure out any pattern...
> Have you tried dumping out another table and does it do the same
> thing?
>
>
>>> But the problem remains: My dbf file shows, for example, the column
>>> "id" and another "id_01". So all columns are doubled and an "_01"
>>> added to the column name...
>>>
>>> Stef
>>
>>
>> Hi Stefan,
>>
>> Unfortunately there is not enough information here for us to find out
>> what is happening. For example, which version of PostGIS/PostgreSQL
>> are you using? (SELECT version() / SELECT postgis_full_version() ).
>> Also you'd need to supply a .sql file containing the definitions for
>> your table along with 3-4 sample geometries, plus with the resulting
>> DBF file that is produced.
>>
>
> Hi,
>
> here is the command I use to export the table2shapefile:
>
> pgsql2shp -k -f glaciers my_database glaciers
>
> ______________________________________________________________________
> __
> _________________
>
>
> Here are the dbf titels (with one exempl. entry):
>
> id name country_id lat long id_01 name_01
> country_01
> lat_01 long_01
> 1037 Austre Broggerbreen 852 78.8830000000 11.8330000000
>
> 1037 Austre Broggerbreen 852 78.8830000000 11.8330000000
>
> ______________________________________________________________________
> __
>
> _________________
>
>
> PostGIS version:
>
> PostgreSQL 8.1.2 on powerpc-apple-darwin8.4.0, compiled by GCC
> powerpc-apple-darwin8-gcc-4.0.1 (GCC) 4.0.1 (Apple Computer, Inc.
> build 5247)
> POSTGIS="1.1.1" GEOS="2.2.1-CAPI-1.0.1" PROJ="Rel. 4.4.9, 29 Oct
>
> 2004" USE_STAT
>
> ______________________________________________________________________
> __
>
> _________________
>
>
> And here is the SQL file for the table:
>
> SET SESSION AUTHORIZATION 'ss_admin';
>
> SET search_path = "public", pg_catalog;
>
> -- Definition
>
> -- DROP TABLE "public"."glaciers";
> CREATE TABLE "glaciers" (
> "id" integer NOT NULL,
> "name" character varying(23),
> "country_id" integer,
> "lat" double precision,
> "long" double precision,
> "the_geom" geometry,
> CONSTRAINT "glaciers_pkey" PRIMARY KEY (id)
> ) WITH OIDS;
>
> COPY "glaciers" FROM stdin;
> 1037 Austre Broggerbreen 852 78.882999999999996 11.833
>
> 00000000014027AA7EF9DB22D14053B883126E978D
> 1050 Cares\\303\\250r 444 46.5 10.667
> 0000000001402555810624DD2F4047400000000000
> 1055 Djankuat 748 43.200000000000003
> 42.767000000000003
> 00000000014045622D0E560419404599999999999A
> 1035 Enchaurren Norte 180 -33.582999999999998
> -70.132999999999996
> 0000000001C0518883126E978DC040CA9FBE76C8B4
> 1039 Engabreen 672 66.650000000000006 13.85
> 0000000001402BB333333333334050A9999999999A
> 1049 Gries 864 46.5 8.3000000000000007
> 0000000001402099999999999A4047400000000000
> 1043 Gr\\303\\245subreen 672 61.649999999999999
> 8.5999999999999996
> 00000000014021333333333333404ED33333333333
> 1031 Gulkana 944 63.267000000000003 -145.417
> 0000000001C0622D5810624DD3404FA22D0E560419
> 1045 Hardangerjokulen 672 60.533000000000001 7.367
>
> 0000000001401D77CED916872B404E44395810624E
> 1041 Hellstugubreen 672 61.566000000000003
> 8.4329999999999998
> 00000000014020DDB22D0E5604404EC872B020C49C
> 1052 Hintereisferner 56 47.082999999999998 10.917
> 00000000014025D5810624DD2F40478A9FBE76C8B4
> 1053 Kesselwandferner 56 46.829999999999998
> 10.800000000000001
> 0000000001402599999999999A40476A3D70A3D70A
> 1060 Leviy Aktru 748 50.082999999999998
> 87.683000000000007
> 00000000014055EBB645A1CAC140490A9FBE76C8B4
> 1059 Maliy Aktru 748 50.082999999999998 87.75
> 00000000014055F0000000000040490A9FBE76C8B4
> 1036 Midre Lov\\303\\251nbreen 852 78.882999999999996
> 12.067
> 00000000014028224DD2F1A9FC4053B883126E978D
> 1044 Nigardsbreen 672 61.716999999999999 7.133
> 0000000001401C883126E978D5404EDBC6A7EF9DB2
> 1058 No. 125 (Vodopadniy) 748 50.100000000000001
> 87.700000000000003
> 00000000014055ECCCCCCCCCCD40490CCCCCCCCCCD
> 1033 Place 160 50.433 -122.59999999999999
> 0000000001C05EA666666666664049376C8B439581
> 1048 Sarennes 304 45.109999999999999
> 6.1660000000000004
> 00000000014018A9FBE76C8B4440468E147AE147AE
> 1046 Silvretta 864 46.832999999999998 10.08
> 0000000001402428F5C28F5C2940476A9FBE76C8B4
> 1051 Sonnblickkees 56 47.049999999999997
> 12.949999999999999
> 00000000014029E666666666664047866666666666
> 1034 South Cascade 944 48.350000000000001 -121.05
> 0000000001C05E43333333333340482CCCCCCCCCCD
> 1047 St. Sorlin 304 45.183 6.1660000000000004
> 00000000014018A9FBE76C8B444046976C8B439581
> 1040 Storbreen 672 61.566000000000003
> 8.1329999999999991
> 0000000001402044189374BC6A404EC872B020C49C
> 1038 Storglaci\\303\\244ren 860 67.900000000000006 18.567
>
> 000000000140329126E978D4FE4050F9999999999A
> 1056 Tsentralniy Tuyuksuyski 476 43.049999999999997
> 77.082999999999998 00000000014053454FDF3B645A4045866666666666
> 1057 Urumqihe S. No. 1 184 43.082999999999998
> 86.816999999999993
> 00000000014055B449BA5E353F40458A9FBE76C8B4
> 1054 Vernagtferner 56 46.883000000000003 10.817
> 00000000014025A24DD2F1A9FC4047710624DD2F1B
> 1032 Wolverine 944 60.399999999999999 -148.917
>
> 0000000001C0629D5810624DD3404E333333333333
> 1042 \\303\\205lfotbreen 672 61.75 5.6500000000000004
>
> 0000000001401699999999999A404EE00000000000
> \.
>
> -- Indexes
>
> CREATE UNIQUE INDEX glaciers_pkey ON glaciers USING btree (id);
> CREATE INDEX glaciers_the_geom_gist ON glaciers USING gist (the_geom);
>
> ______________________________________________________________________
> __
>
> _________________
>
>
> Hope this helps to identify the problem.
>
> Thanks for your precious help!
>
> Stef
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
> -----------------------------------------
> The substance of this message, including any attachments, may be
> confidential, legally
> privileged and/or exempt from disclosure pursuant to Massachusetts
> law. It is intended
> solely for the addressee. If you received this in error, please
> contact the sender and
> delete the material from any computer.
>
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
More information about the postgis-users
mailing list