public static boolean hasChildren(Long id) { long count = Region.count("parentid=?", id); boolean has = false; if (count > 0) { has = true; } return has; }