Hello uc1bear,
Thank you for asking such an interesting question. I had previously
searched for the same thing for my personal use, so locating such a
source was not difficult. After some research, I found this file
online:
http://www.census.gov/ftp/pub/tiger/tms/gazetteer/places2k.txt
Since the file contains some extraneous information, I wrote a Java
program to cut them off, leaving only the city names as you wanted.
You can download this file here:
http://www.lucidmatrix.com/uploads/places2kedited.txt
Please note that the city names are in the order that they appear in
the original file. If you'd like to put them in alphabetical order or
format them in another way, please let me know.
If you need clarification, please ask for it before rating this
answer.
secret901-ga
Search strategy:
"US Cities" site:.gov
inurl:places2k.txt
Thanks scriptor :-) |
Clarification of Answer by
secret901-ga
on
20 Jan 2003 15:33 PST
Here is another file which removes the ending in the city names (city,
town, village, etc) and leaves only the name of the city themselves.
http://www.lucidmatrix.com/uploads/places2kedited.txt
secret901-ga
|
Clarification of Answer by
secret901-ga
on
20 Jan 2003 15:35 PST
Oops, sorry. The previous link should be:
http://www.lucidmatrix.com/uploads/places2kedited2.txt
Sorry for the confusion.
secret901-ga
|
Request for Answer Clarification by
uc1bear-ga
on
20 Jan 2003 16:56 PST
Hi Secret901,
That text file was 97% what I was looking for. The minor problem was
that it required a bit of cleanup, as many of the locations had words
like 'town', 'city', 'urbana' (there were some Mexican cities), and
such after them.
If you can find one more small bit of daya, I'll be happy to give you
a perfect rating... A list of either all 50 states (shouldn't be
tough!) and/or all/most countries. Thanks again. Looking forward to
it!
uc
|
Clarification of Answer by
secret901-ga
on
20 Jan 2003 17:17 PST
The cleanup was done in the previous clarification. Click on the link
to see the cleaned up version :-)
The list of counties is found here:
http://www.census.gov/tiger/tms/gazetteer/county2k.txt
I've cleaned it up with my handy program:
http://www.lucidmatrix.com/uploads/county2kedited.txt
Edited even more to remove the trailing "County", "Municipality", or
"Census Area":
http://www.lucidmatrix.com/uploads/county2kedited2.txt
List of states:
http://www.lucidmatrix.com/uploads/states.txt
I hope that this is what you're looking for!
If you need more clarification, please let me know.
secret901-ga
|
Clarification of Answer by
secret901-ga
on
20 Jan 2003 17:23 PST
Just a note of clarification: The cities and towns with Spanish names
are in Puerto Rico. If you'd like me to exclude them, please let me
know and I'll remove them from the list.
|
Clarification of Answer by
secret901-ga
on
20 Jan 2003 17:42 PST
How silly of me! You said countries, not counties!
Here are the countries of the world, adapted from the CIA website:
http://www.lucidmatrix.com/uploads/Countries.txt
secret901-ga
|
Request for Answer Clarification by
uc1bear-ga
on
06 Feb 2003 19:35 PST
Hi Secret901,
Just posted a new question that you may know the answer to. Thanks, M
|
Clarification of Answer by
secret901-ga
on
06 Feb 2003 21:21 PST
Hi M,
Unfortunately, I am unable to locate your question. Please post a link to it.
|
Request for Answer Clarification by
uc1bear-ga
on
26 Apr 2003 14:43 PDT
Hi Secret,
Any chance you can re-work the cleaning script to leave on the
two-letter state abbreviation, along with the cleaned city name
(already there)? It's woth a $5 tip to me, and should be pretty
quick! Thanks, uc
|
Clarification of Answer by
secret901-ga
on
26 Apr 2003 20:58 PDT
Hi uc1bear,
I apologize if this is response is late. I haven't been on Google all
day.
Here is the link to the new file:
http://www.geocities.com/secret901/places2kkedited3.txt
I added the two-letter state abbreviation in the normal manner (e.g.
Los Angeles, CA). If you'd like them to be in a different format, let
me know.
Unfortunately, it's not possible to tip once you have rated an answer.
If you wish, you can open a new question directed to me, although
this is a totally voluntary.
secret901-ga
|
Clarification of Answer by
secret901-ga
on
26 Apr 2003 21:02 PDT
Oops, the last line should read "although this is totally voluntary."
secret901-ga
|
Request for Answer Clarification by
uc1bear-ga
on
30 Apr 2003 18:32 PDT
THANKS, Secret901.
Please see question 197730 for your tip!
|
Clarification of Answer by
secret901-ga
on
01 May 2003 00:14 PDT
Hi uc1bear,
Thank you for the nice rating and the tip. Please use our service
again if you need anything done.
secret901-ga
|