return new NullComparator();
// otherwise, use the schema of the first tuple in the set
s = ((Tuple)ts.tuples().next()).getSchema();
}
// create the comparator
CompositeComparator cc = new CompositeComparator(m_fields.length);
for ( int i=0; i<m_fields.length; ++i ) {
cc.add(new TupleComparator(m_fields[i],
s.getColumnType(m_fields[i]), m_ascend[i]));
}
return cc;
}