El dom, 29-12-2002 a las 14:35, Reshat Sabiq escribió:
> I believe it is not possible yet in postreSQL, but in case it is what
> would be the equivalent of the following Oracle statement (assuming
> current myfield size to be 10 bytes (of type char)):
> ALTER TABLE mytable MODIFY (myfield CHAR(12));
> If it's currently not supported is there a way to submit an RFE?
It's not supported. You can instead create a new table with the field
already as you want it to be, and transfer data, as explained in .
Another possible way, if you are using PostgreSQL 7.3, it already
supports dropping columns so you can create a new column myfield_temp as
char(12), copy values from myfield, drop myfield and rename myfield_temp
to myfield. You should keep in mind that default and NOT NULL are not
supported in ADD COLUMN and you should use SET DEFAULT or SET NOT NULL
aftewards as required.
Alberto Caso Palomino
Adaptia Soluciones Integrales
In response to
- innodb at 2002-12-30 09:49:26 from Reshat Sabiq
pgsql-novice by date
|Next:||From: Reshat Sabiq||Date: 2002-12-30 09:49:26|
|Previous:||From: Alberto Caso||Date: 2002-12-29 17:08:27|
|Subject: Re: sequence generator programmatic invocation(preferably|