akashrn5 commented on a change in pull request #4015: URL: https://github.com/apache/carbondata/pull/4015#discussion_r533614590
########## File path: integration/spark/src/main/scala/org/apache/spark/sql/secondaryindex/rdd/SecondaryIndexCreator.scala ########## @@ -398,6 +404,22 @@ object SecondaryIndexCreator { secondaryIndexModel.sqlContext.sparkSession, carbonLoadModelForMergeDataFiles.getFactTimeStamp, rebuiltSegments) + + if (isInsertOverwrite) { + FileInternalUtil + .updateTableStatus( + SegmentStatusManager + .readLoadMetadata(indexCarbonTable.getMetadataPath) + .filter(loadMetadata => !successSISegments.contains(loadMetadata.getLoadName)) + .map(_.getLoadName).toList, + secondaryIndexModel.carbonLoadModel.getDatabaseName, Review comment: please do not add complete filter logic inside a method parameter, please assign that to a variable for clean code practice. ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org