Ya now i am getting error code which says SQLITE_DONE...so how can get my
resultant now?
Which API i should use?Please tell me


----- Original Message ----- 
From: "Igor Tandetnik" <[EMAIL PROTECTED]>
To: "SQLite" <sqlite-users@sqlite.org>
Sent: Friday, September 15, 2006 7:57 PM
Subject: [sqlite] Re: Which API to use to get resultant of query


> sandhya <[EMAIL PROTECTED]> wrote:
> > sprintf(szQuery,"select oid from %s where filename =
> > '%s'",sampletbl,test.htm);
> >
> > sqlite3_prepare(db,szQuery, 512 , &pStmt, 0);
>
> It is unlikely that szQuery string is 512 characters long. So you
> instruct SQLite to compile a long string of garbage. sqlite3_prepare
> most likely fails (I can't help but note that you don't check error code
> here). Just pass -1 as the third parameter.
>
> > errcode = sqlite3_step(pStmt);
> >
> > But the error code i am getting is 21
>
> This means sqlite3_prepare has failed, pStmt remains uninitialized so
> you are passing garbage to sqlite3_step.
>
> Igor Tandetnik
>
>
> --------------------------------------------------------------------------
---
> To unsubscribe, send email to [EMAIL PROTECTED]
> --------------------------------------------------------------------------
---
>



-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------

Reply via email to