First of all you shouldn't put code in .h files --- only declarations.
Here you declare a new local variable DB, which has nothing to do (except for the name) with the DB variable from your previous post.
Does this even compile? Note that variable names are case sensitive, so there's a difference between db and DB.
Bookmarks