Subject Re: [firebird-support] FB sql compilation: buffered or not?
Author Ann Harrison
lnd@... wrote:

> Is it possible to:
>- specify how large the "buffer" can be?
Any statement you prepare will be buffered until you release it.

>- get some statistics of its performance: how many staments are found and how
>many compiled?
Given the architecture, that question has no real meaning.

>- to "pin" some statements permanently in the buffer: the issue is that
>"lexical SQL" (kind of "select .. where name='john' ") is wasting space of
>any buffer by forcing "good SQL" statements out of it.
It's not that kind of a buffer. Any statement that's submitted as an
"execute immediate" is compiled and released automatically. Any
statement that's prepared will be buffered until its released. However
compiled statements are kept in a buffer that is specific to a single

>In that light is makes
>sense to tell RDBMS that some statements have to be in the buffer
>permanently, e.g. those executed 10x per second. Well, this is impossible
>probably as the buffer is not shared between connections.
Something that is likely to appear in a future version is a compiled
statement cache which will be cross connection.