Skip to content

Commit d32cd1b

Browse files
committed
Forgot to handle column length defaults in ALTER TABLE ADD COLUMN.
1 parent 7cc0d6a commit d32cd1b

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

src/backend/parser/analyze.c

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
*
66
* Copyright (c) 1994, Regents of the University of California
77
*
8-
* $Id: analyze.c,v 1.131 2000/01/20 02:24:50 tgl Exp $
8+
* $Id: analyze.c,v 1.132 2000/01/22 01:22:48 tgl Exp $
99
*
1010
*-------------------------------------------------------------------------
1111
*/
@@ -178,6 +178,18 @@ transformStmt(ParseState *pstate, Node *parseTree)
178178
}
179179
break;
180180

181+
case T_AlterTableStmt:
182+
{
183+
AlterTableStmt *n = (AlterTableStmt *) parseTree;
184+
185+
result = makeNode(Query);
186+
result->commandType = CMD_UTILITY;
187+
if (n->subtype == 'A') /* ADD COLUMN */
188+
transformColumnType(pstate, (ColumnDef *) n->def);
189+
result->utilityStmt = (Node *) parseTree;
190+
}
191+
break;
192+
181193
/*------------------------
182194
* Optimizable statements
183195
*------------------------

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy