What NathanOliver gave you was a link to how to do input from and output to text files. Here's another link in that regard http://www.cplusplus.com/doc/tutorial/files/ It seemed initially like that was what you were asking about.

What kind of database would you be interested in? A database is probably overkill if you are just trying to maintain a list of those countries. If you really need a database check into MySQL (www.mysql.com), there is a C++ binding to interact with it.