That's another whole subject, and should really be a new thread.
You ought to read that first link I gave you one more time.
Just like *nix line endings, and the use of nano, there is a lot of information about what to "do in database.yml" to be found on the web with a little google grease (just search and read). I don't mind helping you, but you probably should do some of the research on this stuff yourself and make an effort to understand what you are trying to do before asking others to "walk you through" each step.
I'm sure that, once you have done some studying and some research on your own, if you open a new thread about your database.yml problem with a specific question, there are those here who will help you further. Good Luck!