I highly recommend you read this book: OpenLayers 2.10 Beginner's Guide 2011 Eric Hazzard.
For beginners like you, this book offers many documents with a corresponding example regarding a KML file.
And for the database you can use PostgreSQL 9.0. Just helping. Good luck.
source
share