@@ -585,7 +585,6 @@ impl TableMetadataBuilder {
585585 if schema_found {
586586 if self . last_added_schema_id != Some ( new_schema_id) {
587587 self . changes . push ( TableUpdate :: AddSchema {
588- last_column_id : Some ( self . metadata . last_column_id ) ,
589588 schema : schema. clone ( ) ,
590589 } ) ;
591590 self . last_added_schema_id = Some ( new_schema_id) ;
@@ -609,10 +608,7 @@ impl TableMetadataBuilder {
609608 . schemas
610609 . insert ( new_schema_id, schema. clone ( ) . into ( ) ) ;
611610
612- self . changes . push ( TableUpdate :: AddSchema {
613- schema,
614- last_column_id : Some ( self . metadata . last_column_id ) ,
615- } ) ;
611+ self . changes . push ( TableUpdate :: AddSchema { schema } ) ;
616612
617613 self . last_added_schema_id = Some ( new_schema_id) ;
618614
@@ -1453,10 +1449,7 @@ mod tests {
14531449 TableUpdate :: SetLocation {
14541450 location: TEST_LOCATION . to_string( )
14551451 } ,
1456- TableUpdate :: AddSchema {
1457- last_column_id: Some ( LAST_ASSIGNED_COLUMN_ID ) ,
1458- schema: schema( ) ,
1459- } ,
1452+ TableUpdate :: AddSchema { schema: schema( ) } ,
14601453 TableUpdate :: SetCurrentSchema { schema_id: -1 } ,
14611454 TableUpdate :: AddSpec {
14621455 // Because this is a new tables, field-ids are assigned
@@ -1509,7 +1502,6 @@ mod tests {
15091502 location: TEST_LOCATION . to_string( )
15101503 } ,
15111504 TableUpdate :: AddSchema {
1512- last_column_id: Some ( 0 ) ,
15131505 schema: Schema :: builder( ) . build( ) . unwrap( ) ,
15141506 } ,
15151507 TableUpdate :: SetCurrentSchema { schema_id: -1 } ,
@@ -1751,7 +1743,6 @@ mod tests {
17511743 Some ( & Arc :: new( added_schema. clone( ) ) )
17521744 ) ;
17531745 pretty_assertions:: assert_eq!( build_result. changes[ 0 ] , TableUpdate :: AddSchema {
1754- last_column_id: Some ( 4 ) ,
17551746 schema: added_schema
17561747 } ) ;
17571748 assert_eq ! ( build_result. changes[ 1 ] , TableUpdate :: SetCurrentSchema {
0 commit comments