Okay, let's try asking the question this way then.  How do I know if I need to 
call prepare based on the condition or value or whatever of a statement that 
may or may not have already been passed to perpare as a parameter?
 
> To: sqlite-users@sqlite.org
> From: itandet...@mvps.org
> Date: Tue, 9 Mar 2010 12:47:42 -0500
> Subject: Re: [sqlite] How can I query a sqlite3_stmt to find out if ithas 
> been run through the sqlite3_prepare_v2 function?
> 
> Ed Curren <ecur...@hotmail.com> wrote:
> > This function will be called several times. The first time through
> > the statment won't be prepared
> 
> What do you mean, won't be prepared? How can one obtain a statement handle 
> without calling prepare?
> 
> > so in that case the function will
> > call sqlite3_preapre_v2 to prepare the statement.
> 
> Note that sqlite3_preapre_v2 doesn't take a statement as a parameter. It 
> takes a database connection and a SQL string, and _produces_ the statement 
> from them.
> 
> Imagine one saying "I have a FILE* handle and I need to call fopen on it", or 
> "I have a void* pointer and I need to call malloc on it". Well, your question 
> makes about as much sense.
> 
> Igor Tandetnik
> 
> 
> _______________________________________________
> 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

Reply via email to