I'm not sure if this best belongs here, but I'm using MySQL. I want to make a 'list' of geographical names. This is for metadata describing pictures and articles. I did some power-googling, had trouble finding stuff. My idea for the list:
-one table with all the names in it. (countries, prov's/states, districts/counties, municipalities, etc.)
-each name type is assigned a level # according to its type, 1 for countries, 2 for prov/states, down the line to the smallest unit (could be street names/numbers or even individual addresses). geographical features/areas unclassifiable by political boundaries are assigned #0.
-the database starts off with some practical names in it - the ones most likely to be needed by users. the user selects from level 1 and down to where they feel is specific enough. (if they're unsure about the exact location, they can stop at the province/state level, or skip the district/county level)
-a level 0 name can be added anywhere in the tree
-if a name is not in the list, which may often happen with city names or lesser levels, there is a box to type one in. This 'proposal' can then be approved by webmaster or whomever, and added to the database.
-there is no
actual heirarchy, it's implied by sorting items by level #'s
-only one of each type may be selected for each entry, stored in another table, types comma-delimited, disparate locations semicolon-delimited.
Is this practical and efficient? Any links about this type of database? Thoughts? Opinions? Fire at will!
