[postgis-devel] more small shp2pgsql patches
strk
strk at keybit.net
Thu Aug 5 09:53:48 PDT 2004
On Thu, Aug 05, 2004 at 12:45:09PM -0400, Carl Anderson wrote:
> not sure if first patch got through so I'm resending with an addition
committed. thanks.
--strk;
>
> C.
>
> --
> Carl Anderson
> GIS Manager Fulton County, Georgia
> carl.anderson at co.fulton.ga.us
> 404.730.8026
>
> --- shp2pgsql.c.old Thu Aug 5 09:07:04 2004
> +++ shp2pgsql.c Thu Aug 5 09:13:20 2004
> @@ -921,8 +921,16 @@
>
> if (!dump_format)
> {
> - printf("INSERT INTO \"%s\" %s VALUES ('%d',",
> + if ( schema )
> + {
> + printf("INSERT INTO \"%s\".\"%s\" %s VALUES ('%d',",
> + schema, table, col_names, j);
> + }
> + else
> + {
> + printf("INSERT INTO \"%s\" %s VALUES ('%d',",
> table, col_names, j);
> + }
> }
> else
> {
> --- pgsql2shp.c.old Thu Aug 5 09:13:54 2004
> +++ pgsql2shp.c Thu Aug 5 12:40:08 2004
> @@ -2393,6 +2393,7 @@
> sprintf(query, "SELECT a.attname, a.atttypid, a.attlen FROM "
> "pg_attribute a, pg_class c, pg_namespace n WHERE "
> "n.nspname = '%s' AND a.attrelid = c.oid AND "
> + "n.oid = c.relnamespace AND "
> "a.atttypid != 0 AND "
> "a.attnum > 0 AND c.relname = '%s'", schema, table);
> }
> _______________________________________________
> postgis-devel mailing list
> postgis-devel at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-devel
More information about the postgis-devel
mailing list