Hello Igor,

On 7 Dec 2008, at 10:49 PM, Igor Tandetnik wrote:

> "Tito Ciuro" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
>> 1 • Create the object using sqlite3_prepare_v2() or a related
>> function. 2 • Bind values to host parameters using the
>> sqlite3_bind_*() interfaces.
>> 3 • Run the SQL by calling sqlite3_step() one or more times.
>> 4 • Reset the statement using sqlite3_reset().
>> 5 • Clear bindings using sqlite3_clear_bindings() then go back to  
>> step
>> 2. Do this zero or more times.
>
> This step is optional. You don't need to call sqlite3_clear_bindings.
> You might want to if most of your parameters are NULL, and you just  
> bind
> a some of them.
>
>> 6 • Destroy the object using sqlite3_finalize().
>>
>> If step 5 is incorrect, when should I be calling
>> sqlite3_clear_bindings ()?
>
> You don't have to, if you don't want to.

I'm curious as to why it's not needed. Is it because the latter bind  
overrides the former one? I'd like to know why sqlite3_clear_bindings 
() exists in the first place. Is it being kept around for backwards  
compatibility?

Thank you,

-- Tito
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to