Marten Feldtmann <[EMAIL PROTECTED]> wrote:
> John Stanton schrieb:
> > Maybe your statement does not reference a valid row.
> >
> No, actually I have in my test program several lines to retrieve
> the values in different ways:
>
> sql = "select aColumn from TESTME2;";
> sqlite3_open("c:\\sunittest.db", &db);
> sqlite3_prepare(db, sql, strlen(sql), &stmt, NULL);
> rc = sqlite3_step(stmt);
>
> /* ----------------------------------- */
>
> /* this is ok and returns "5000.0" */
> txt = sqlite3_column_text( stmt, 0);
>
> /* this works */
> sqlite3_column_double( stmt, 0);
>
> /* this crashed ...
> dVal = sqlite3_column_double( stmt, 0);
>
> /* ----------------------------------- */
> sqlite3_finalize(stmt);
> sqlite3_close(db);
> return( dVal);
>
Make sure sqlite3_column_double() really is declared to
return a double and that dVal really is declared to be a
double. If both of those things check out, then I would
assert that this is a compiler bug.
--
D. Richard Hipp <[EMAIL PROTECTED]>
-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------