SeSqlConstruct sqlConstruct = new SeSqlConstruct();
String[] tables = {METADATA_TABLE };
sqlConstruct.setTables(tables);
String[] propertyNames = { METADATA_COLUMN };
SeQuery query = new SeQuery(seConnection);
query.prepareQuery(propertyNames, sqlConstruct);
query.execute();
// it is not documented in the ArcSDE API how you know there are no more rows to fetch!
// I'm assuming: query.fetch returns null (empiric tests indicate this assumption is correct).
boolean allRowsFetched = false;