Re: changing a definition in a dump file? - Mailing list pgsql-sql

From Stephan Szabo
Subject Re: changing a definition in a dump file?
Date
Msg-id 20020118085623.J63900-100000@megazone23.bigpanda.com
Whole thread Raw
In response to changing a definition in a dump file?  ("postgresql" <pgsql@symcom.com>)
List pgsql-sql
On Fri, 18 Jan 2002, postgresql wrote:

> Hi all,
> I think I inadvertently sent this to pg-admin...
>
> Is it possible to change the definitions in the dump file to alter a
> table.
>
> this is from my �pgdump file:
>
> CREATE TABLE "fc_client_info" (
> � �"acode" character varying(12),
> � �"cname" character varying(32)
> );
>
> If I change the file to read:
>
> CREATE TABLE "fc_client_info" (
> � �"acode" character varying(12),
> � �"cname" character varying(128)
> );
>
> Can I drop the database and read in the altered pgdump file to effect the
> change?

A dropdb, createdb, read pgdump should do what you want in this case.
In general you need to be sure that the data works for the changes
you're making but lengthening a varchar should be fine.




pgsql-sql by date:

Previous
From: "postgresql"
Date:
Subject: changing a definition in a dump file?
Next
From: Marius Andreiana
Date:
Subject: psql bug: copy paste statements looses tab character