nightmare82 / sqdbcpp Goto Github PK
View Code? Open in Web Editor NEWAutomatically exported from code.google.com/p/sqdbcpp
Automatically exported from code.google.com/p/sqdbcpp
I've got some minor tweaks and stuff, would like to contribute but have no way
to contact the author...
Original issue reported on code.google.com by [email protected]
on 3 Apr 2012 at 3:38
What steps will reproduce the problem?
1. Compile with sqlite3 version < 3.5.0 installed
What is the expected output? What do you see instead?
Compiler error about sqlite3_open_v2 being undefined
What version of the product are you using? On what operating system?
I am on CentOS but it does not matter. This is an issue with the SQLite
library version.
git log says:
commit af1718a8f315c4e5c4294322d7be0eb758444143
Author: Wongoo Lee
Date: Fri May 25 10:24:55 2012 -0700
Please provide any additional information below.
See SQLite 3.5.0 release notes at http://www.sqlite.org/34to35.html
The solution is to wrap the sqlite3pp::database::connect_v2 declaration and
definition like this:
// sqlite3pp.h ~line 67
#if SQLITE_VERSION_NUMBER >= 3005000 // sqlite3_open_v2 not available until
sqlite 3.5.0
int connect_v2(char const* dbname, int flags, char const* vfs = 0);
#endif
// sqlite3pp.cpp ~line 93
#if SQLITE_VERSION_NUMBER >= 3005000 // sqlite3_open_v2 not available until
sqlite 3.5.0
int database::connect_v2(char const* dbname, int flags, char const* vfs)
{
disconnect();
return sqlite3_open_v2(dbname, &db_, flags, vfs);
}
#endif
You could, of course, decide to simply call connect from connect_v2 in the case
that SQLite is not the right version. However, this seems more risky since,
presumably, the caller wanted to use the extended features of the v2 interface.
I think it is better to let the library user make the decision explicitly.
Original issue reported on code.google.com by [email protected]
on 2 Aug 2012 at 11:59
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.