Set<Long> input = new HashSet<Long>();
// Every field is required
LogicalSchema s = distinct.getSchema();
if (s == null) {
throw new SchemaNotDefinedException("Schema for " + distinct.getName() + " is not defined.");
}
for(int i=0; i<s.size(); i++) {
input.add(s.getField(i).uid);
}