MCPcopy Create free account
hub / github.com/apache/cloudberry / generateDefaultPartition

Function generateDefaultPartition

src/backend/parser/parse_partition_gp.c:1155–1175  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1153}
1154
1155static List *
1156generateDefaultPartition(ParseState *pstate,
1157 Relation parentrel,
1158 GpPartDefElem *elem,
1159 PartitionSpec *subPart,
1160 partname_comp *partnamecomp,
1161 CreateStmtOrigin origin)
1162{
1163 PartitionBoundSpec *boundspec;
1164 CreateStmt *childstmt;
1165
1166 boundspec = makeNode(PartitionBoundSpec);
1167 boundspec->is_default = true;
1168 boundspec->location = -1;
1169
1170 /* default partition always needs name to be specified */
1171 Assert(elem->partName != NULL);
1172 childstmt = makePartitionCreateStmt(parentrel, elem->partName, boundspec, subPart,
1173 elem, partnamecomp, origin);
1174 return list_make1(childstmt);
1175}
1176
1177static char *
1178extract_tablename_from_options(List **options)

Callers 1

generatePartitionsFunction · 0.85

Calls 1

makePartitionCreateStmtFunction · 0.85

Tested by

no test coverage detected