Simplifing the code sample for GitHub formating

This commit is contained in:
Sébastien Rombauts 2012-04-02 19:27:36 +02:00
parent 83846c890b
commit bad420cffa

View File

@ -34,11 +34,11 @@ int main (void)
{
// Open a database file
SQLite::Database db("example.db3");
std::cout << "SQLite database file " << db.getFilename().c_str() << " opened successfully\n";
std::cout << "database file: " << db.getFilename().c_str() << " opened successfully\n";
// Compile a SQL query, containing one parameter (index 1)
SQLite::Statement query(db, "SELECT * FROM test WHERE size > ?");
std::cout << "SQLite statement " << query.getQuery().c_str() << " compiled (" << query.getColumnCount () << " columns in the result)\n";
std::cout << "statement: " << query.getQuery().c_str() << " compiled (" << query.getColumnCount () << " columns)\n";
// Bind the integer value 6 to the first parameter of the SQL query
query.bind(1, 6);
@ -59,7 +59,7 @@ int main (void)
}
catch (std::exception& e)
{
std::cout << "SQLite exception: " << e.what() << std::endl;
std::cout << "exception: " << e.what() << std::endl;
}
}
</pre></code>