public static StorageSegment deleteColumn(String name,
                                              StorageSegment baseSegment,
                                              List<String> deleteColumns) throws IOException {
        List<UpdateColSchema> targetColumns = new ArrayList<>();
        boolean update = false;
        for (ColumnSchema cs : baseSegment.schema().getColumns()) {
            if (indexWhere(deleteColumns, c -> cs.getName().equals(c)) >= 0) {
                update = true;
            } else {
                targetColumns.add(new UpdateColSchema(cs.getName(), cs.getSqlType(), cs.isIndexed(), cs.getName()));
            }
        }
        if (!update) {
            return baseSegment;
        }
        return newColumnSchema(name, baseSegment, targetColumns, null);
    }
Remove some columns from the segment. Those nonexsitent columns will be ignored.

@return the new segment. If nothing is changed, returns the original segment instance.
indexr-segment/src/main/java/io/indexr/segment/storage/UpdateColSegment.java