public static int deleteFileByScanPrefixFilter(String tablename, String rowPrifix) {
        HTableInterface table = null;

        int count = 0;
        try {
            table = getTable(tablename);

            Scan s = new Scan();
            s.setFilter(new PrefixFilter(rowPrifix.getBytes()));
            ResultScanner rss = table.getScanner(s);

            for (Result rs : rss) {

                Cell[] cells = rs.rawCells();

                for (Cell cell : cells) {

                    if (toString(CellUtil.cloneQualifier(cell)).equals("repeatFileRowKey")) {

                        String value = toString(CellUtil.cloneValue(cell));

                        if (value.contains(",")) {

                            String rowKeys[] = value.split(",");
                            // 根据文件标题删除重复的文件，留最后一个
                            if (rowKeys != null && rowKeys.length > 0) {

                                for (int i = 0; i < rowKeys.length - 1; i++) {

                                    table.delete(new Delete(toBytes(rowKeys[i])));

                                    count = count + 1;

                                }
                            }
                        }
                    }
                }

            }
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            closeTable(table);
        }
        return count;

    }