Hi, ALL, On Thu, Apr 25, 2013 at 2:41 PM, Random Coder <random.co...@gmail.com>wrote:
> On Tue, Apr 23, 2013 at 8:47 PM, Igor Korot <ikoro...@gmail.com> wrote: > > > query = wxString::Format(...); > > if( ( result = sqlite3_prepare_v2( m_handle, query, -1, &stmt, 0 ) ) != > > SQLITE_OK ) > > > > It's been a while since I've worked with wxWidgets, but when I did, > wxString didn't support an implicit conversion like you're using here. > > You need to do something like this for your sqlite_prepare_v2 call: > > sqlite3_prepare_v2(m_handle, (const char*)query.mb_str(wxConvUTF8), -1, > &stmt, 0); > > Though, I suppose if I'm right, this should have failed in some other way > much sooner. > Here is the table description: sqlite> .dump playersdrafted PRAGMA foreign_keys=OFF; BEGIN TRANSACTION; CREATE TABLE playersdrafted(playerid integer, id ineteger, ownerid integer, draftprice double, draftorder integer, draftposition char(2), foreign key(playerid) references players(playerid),foreign key(id) references leagues(id), foreign key (ownerid) references owners(ownerid)); CREATE INDEX id_playerid ON playersdrafted(playerid,id); COMMIT; All primary keys are exist by the time the INSERT INTO.. happens. I even tried to do with sqlite3_exec(), but it is still failing.... Any idea? Thank you. > _______________________________________________ > sqlite-users mailing list > sqlite-users@sqlite.org > http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users > _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users