[prev in list] [next in list] [prev in thread] [next in thread] 

List:       sqlite-users
Subject:    Re: [sqlite] Does prepare do arithmetic?
From:       Richard Hipp <drh () sqlite ! org>
Date:       2017-05-30 23:21:29
Message-ID: CALwJ=MzwOctgjV2Voyo8VVUh5NAz_HTmPGpY0Lpf8yVhGjLvLg () mail ! gmail ! com
[Download RAW message or body]

On 5/30/17, James K. Lowden <jklowden@schemamania.org> wrote:
>
> I didn't know sqlite3_column_text converted the result.  I thought the
> result was constant, and the function returned a string
> representation of it.
>

It might be a good optimization to change that, so that
sqlite3_column_text does in fact keep the original value and just
return a temporary string that is freed at the next sqlite3_step() (or
sqlite3_reset() or sqlite3_finalize()).  That would mean that columns
that are constant do not need to be recomputed at each step.  It is
something to look into.  But I don't think it would make much
difference in most applications, so it is not a huge priority.

-- 
D. Richard Hipp
drh@sqlite.org
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic