mirror of
https://github.com/postgres/postgres.git
synced 2025-04-24 10:47:04 +03:00
ALTER TABLE (text) fix
This commit is contained in:
parent
6da0055274
commit
1a395b7256
@ -7,7 +7,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/commands/Attic/command.c,v 1.6 1996/11/17 04:23:10 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/commands/Attic/command.c,v 1.7 1997/01/02 06:18:25 momjian Exp $
|
||||||
*
|
*
|
||||||
* NOTES
|
* NOTES
|
||||||
* The PortalExecutorHeapMemory crap needs to be eliminated
|
* The PortalExecutorHeapMemory crap needs to be eliminated
|
||||||
@ -444,10 +444,10 @@ PerformAddAttribute(char *relationName,
|
|||||||
}
|
}
|
||||||
namestrcpy(&(attribute->attname), (char*) key[1].sk_argument);
|
namestrcpy(&(attribute->attname), (char*) key[1].sk_argument);
|
||||||
attribute->atttypid = typeTuple->t_oid;
|
attribute->atttypid = typeTuple->t_oid;
|
||||||
if (form->typlen > 0)
|
if (colDef->typename->typlen > 0)
|
||||||
attribute->attlen = form->typlen;
|
|
||||||
else /* bpchar and varchar */
|
|
||||||
attribute->attlen = colDef->typename->typlen;
|
attribute->attlen = colDef->typename->typlen;
|
||||||
|
else /* bpchar, varchar, text */
|
||||||
|
attribute->attlen = form->typlen;
|
||||||
attribute->attnum = i;
|
attribute->attnum = i;
|
||||||
attribute->attbyval = form->typbyval;
|
attribute->attbyval = form->typbyval;
|
||||||
attribute->attnelems = attnelems;
|
attribute->attnelems = attnelems;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user