Aakil Ladhani Aakil Ladhani - 16 days ago 5
iOS Question

Get States list of states according to selected country

I want to retrieve names of all the states list of a particular country which is selected from a drop down menu.

I know how to retrieve the list of all countries via apple code but now i want the list of all the states.

Is there any code db or API available for that?

Answer

You may download this is sqlite file, with the countries and states. you can recreate a query everytime the user sets the country.

NSString *queryString = [NSString stringWithFormat:@"select zone_id , name from
                       zone where country_id = %d", countryID];