local database accessing