How to make sense of video file formats?
File formats are essentially wrappers, a container of sorts. The video information is encoded in a codec (Coder/Decoder). Some file formats only work with certain codecs. This is due (in part) to corporate/organizational pissing contests (or format wars - remember dvd+ vs. dvd -?). Codecs come with varying degrees of compression. The more compressed a codec is, the smaller your files will be, but they will also potentially be losing information, in the same way that a RAW file saves everything from CCD, and JPEG compresses the file by dropping repeated information. Also, most pro level NLEs (like Final Cut Pro (not FCPX)) play nicer with codecs that are less compressed. The more compressed it is the more the computer has to work to decode and re-enconde the information when you make changes (moving on the time line, cutting, adding effects etc.)

Recommendations:
For recording and editing (HD), pick a low compression, high quality codec such as DVCProHD, AVCHD, Apple ProRes.

To export for sharing I recommend H.264. It is supported nearly universally and is very good quality with relatively small files. BluRay videos are actually encoded in an ultra high quality H.264

One other note: if your camcorder saves files in a weird format (ie. not mov, mpeg, mp4), you will need to use a transfer process in your NLE. Be sure to save the ENTIRE folder structure from your memory card, not just the mts, mxf, or whatever files.

More tips: if you're not sure what codec a file is in, you can open it in QuickTime and hit cmd+i to open the inspector window. It will have all the codec information there.
Additionally, on Windows there is a small utility called G-SPOT which can show you what codec are you using on that file etc.