Using a DB with C++ is a real mess and it was refreshing when I moved to Java to be able to use a unified system to abstract the whole layer away (aka Hibernate).
There
I feel your pain. You'll quickly be using separate libraries for database access, XML processing, threading, and everything else applications commonly need. For this reason I often use Qt, which provides most common functionality often need in programs (database access, XML processing, threading, GUI widgets, etc.). Their SQL classes are pretty decent and work with many databases. But it does not abstract SQL away like many object-relation mappers.