int main() {
otl_connect db;
otl_connect::otl_initialize();
db.rlogon("whatever");
int cuarentaydos;
const char *sql = "select 42 drom dual";
otl_stream stmt(1, sql, db);
if (!stmt.eof()) stmt >> cuarentaydos;
std::cout << "En la base 42 == " << cuarentaydos << "n";
db.logoff();
}
I spent half an hour looking for the error. How come drom is not a standard sql keyword? Damn!