How do i get results from a query and print them as a string in c++??

I can connect to my mysql server alright by using "mysql::initialize", and i can send querys properly using mysql::execute("INSERT INTO users ect........") but i dont know how to print results when i use
mysql::execute("SELECT * FROM users WHERE username = 'heath'")
I know how to get the results with the normal mysql in c++, but not with mysqlpp, and the only reason im using mysqlpp is so i can use mysql globally :)

Summerised:
How do i get results from a query and print them as a string in c++

ALSO, how do i get the "connection" variable globally? i tried mysqlpp::connection; but thats not right :P
Last edited on
Topic archived. No new replies allowed.