public static boolean arePrefixColumns(List<FieldSchema> p, List<FieldSchema> s) {
    if (p == s) {
      return true;
    }
    if (p == null || s == null || p.size() > s.size()) {
      return false;
    }
    return areSameColumns(p, s.subList(0, p.size()));
  }
@Test
  public void testPrefixColumns() {
    FieldSchema col1 = new FieldSchema("col1", "string", "col1 comment");
    FieldSchema Col1 = new FieldSchema("Col1", "string", "col1 comment");
    FieldSchema col2 = new FieldSchema("col2", "string", "col2 comment");
    FieldSchema col3 = new FieldSchema("col3", "string", "col3 comment");
    Assert.assertTrue(MetaStoreServerUtils.arePrefixColumns(null, null));
    Assert.assertFalse(MetaStoreServerUtils.arePrefixColumns(Arrays.asList(col1), null));
    Assert.assertFalse(MetaStoreServerUtils.arePrefixColumns(null, Arrays.asList(col1)));
    Assert.assertTrue(MetaStoreServerUtils.arePrefixColumns(Arrays.asList(col1), Arrays.asList(col1)));
    Assert.assertTrue(MetaStoreServerUtils.arePrefixColumns(Arrays.asList(col1, col2), Arrays.asList(col1, col2, col3)));
    Assert.assertTrue(MetaStoreServerUtils.arePrefixColumns(Arrays.asList(Col1, col2), Arrays.asList(col1, col2, col3)));
    Assert.assertFalse(MetaStoreServerUtils.arePrefixColumns(Arrays.asList(col1, col2, col3), Arrays.asList(col1, col2)));
  }