zhangjun0x01 commented on code in PR #965:
URL: https://github.com/apache/incubator-paimon/pull/965#discussion_r1174918364
##########
docs/content/how-to/altering-tables.md:
##########
@@ -195,6 +231,16 @@ The following SQL sets column `coupon_info` to be nullable.
{{< tabs "change-nullability-example" >}}
+{{< tab "Flink" >}}
+
+```sql
+CREATE TABLE T (a STRING PRIMARY KEY NOT ENFORCED, b FLOAT NOT NULL);
+ALTER TABLE T MODIFY b FLOAT;
+```
Review Comment:
> I asked flink community and the answer is `alter table modify column_name
data_type not null`. Can you have a try?
the example of spark is change column from not null to nullable, but I try
the same operation in flink, I have add a test in the `SchemaChangeITCase`,
change the column to not null will throw an exception.
```
assertThatThrownBy(() -> sql("ALTER TABLE T MODIFY c STRING NOT NULL"))
.hasMessageContaining(
"Could not execute ALTER TABLE PAIMON.default.T\n"
+ " MODIFY `c` STRING NOT NULL");
```
--
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]