query = String.format(
"select count(*) from %s group by " + Strings.mult(",", "%s", keyColumns.length) + " having count(*)>1",
formatArgs
);
SQLResult result = SQLUtils.getResultFromQuery(conn, query, null, false);
if (result.rows.length > 0)
throw new RemoteException(String.format(
"Values in the selected column%s do not uniquely identify rows in the table.",
keyColumns.length == 1 ? "" : "s"
));