rambleraptor commented on code in PR #23: URL: https://github.com/apache/iceberg-terraform/pull/23#discussion_r2962807711
##########
internal/provider/resource_table.go:
##########
@@ -96,6 +98,64 @@ func (r *icebergTableResource) Schema(_ context.Context, _
resource.SchemaReques
},
},
},
+ "partition_spec": rscschema.SingleNestedAttribute{
+ Description: "The partition spec of the table.",
+ Optional: true,
+ Computed: true,
+ Attributes: map[string]rscschema.Attribute{
+ "fields": rscschema.ListNestedAttribute{
+ Description: "The fields of the
partition spec.",
+ Required: true,
+ NestedObject:
rscschema.NestedAttributeObject{
+ Attributes:
map[string]rscschema.Attribute{
+ "source_id":
rscschema.Int64Attribute{
+
Description: "The source field ID.",
+
Required: true,
+ },
+ "name":
rscschema.StringAttribute{
+
Description: "The partition field name.",
+
Required: true,
+ },
+ "transform":
rscschema.StringAttribute{
+
Description: "The partition transform.",
+
Required: true,
+ },
+ },
+ },
+ },
+ },
+ },
+ "sort_order": rscschema.SingleNestedAttribute{
+ Description: "The sort order of the table.",
+ Optional: true,
+ Computed: true,
+ Attributes: map[string]rscschema.Attribute{
+ "fields": rscschema.ListNestedAttribute{
+ Description: "The fields of the
sort order.",
+ Required: true,
+ NestedObject:
rscschema.NestedAttributeObject{
+ Attributes:
map[string]rscschema.Attribute{
+ "source_id":
rscschema.Int64Attribute{
+
Description: "The source field ID.",
+
Required: true,
+ },
+ "transform":
rscschema.StringAttribute{
+
Description: "The sort transform.",
+
Required: true,
+ },
+ "direction":
rscschema.StringAttribute{
+
Description: "The sort direction (asc or desc).",
+
Required: true,
+ },
+ "null_order":
rscschema.StringAttribute{
+
Description: "The null order (nulls-first or nulls-last).",
+
Required: true,
+ },
Review Comment:
Added both!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
