private void deletePreferedByCity() { preferenceDao .queryBuilder() .where( DBPreferenceDao.Properties.City.eq(city.toUpperCase()), DBPreferenceDao.Properties.Country.eq(country), DBPreferenceDao.Properties.State.eq(province)) .buildDelete() .executeDeleteWithoutDetachingEntities(); }
private void loadSavedAttrList() { List<DBPreference> preferedCompanyInThisCity = preferenceDao .queryBuilder() .where( DBPreferenceDao.Properties.City.eq(city.toUpperCase()), DBPreferenceDao.Properties.Country.eq(country), DBPreferenceDao.Properties.State.eq(province)) .list(); if (preferedCompanyInThisCity.size() == 0) { preferedAttrList = ""; } else { preferedAttrList = preferedCompanyInThisCity.get(0).getAttributeList(); } }