Hi Yang,

Thanks for your feedback.


The enableAutoIncrement() method follows the same pattern as `withComment()` 
[1] in schema builder. So it converts the previous column into an 
auto-increment column within the schema builder.


[1] https://github.com/apache/fluss/blob/main/fluss-common/src/main/java/org/apache/fluss/metadata/Schema.java#L252


Regards,
Cheng



 




------------------ Original ------------------
From:                                                                           
                                             "dev"                              
                                                      
<[email protected]&gt;;
Date:&nbsp;Fri, Sep 19, 2025 07:54 PM
To:&nbsp;"dev"<[email protected]&gt;;

Subject:&nbsp;Re: [DISCUSS] FIP-16: auto-increment column



Hi Cheng,

Thank you for driving this FIP. I think it is a nice and important feature
for many real-world business scenarios, and the overall design makes sense
to me. I have just one small question:
Regarding the client-side API design:
```
Schema.newBuilder()
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; .column("uid", DataTypes.STRING())
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; .column("uid_int64", 
DataTypes.BIGINT())
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; .enableAutoIncrement()
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; .primaryKey("uid")
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; .build();
```
If there is more than one column with INT or BIGINT type, which one would
be the auto-increment column?

Best regards,
Yang

Wang Cheng <[email protected]&gt; ??2025??9??18?????? 22:49??????

&gt; Hi all,
&gt;
&gt;
&gt; Auto-increment column is a bread-and-butter feature for improving data
&gt; management efficiency. It is the bedrock of many features in analytical
&gt; workloads??such as those in real-time unique visitor (UV) counting 
scenarios.
&gt;
&gt;
&gt; To implement this capability, I'd like to propose FIP-16: auto-increment
&gt; column [1].
&gt;
&gt;
&gt; Any feedback and suggestions on this proposal are welcome!
&gt;
&gt;
&gt; [1]:
&gt; 
https://cwiki.apache.org/confluence/display/FLUSS/FIP-16%3A+Auto-Increment+Column
&gt;
&gt;
&gt;
&gt;
&gt; Regards,
&gt; Cheng
&gt;
&gt;
&gt;
&gt; &amp;nbsp;

Reply via email to