Subject Re: [firebird-support] Re: it's possible to have a view cache?
Author Martijn Tonies
> thanks for your reply,
> with 'my yable has read-only records' i mean that existing record cannot
> be updated or deleted, the only write operation allowed on that table is
> to add new records but this constraint is only implemented at
> client-application level (ie using another client application as isql tool
> an user can update a row of that table).
>
> i don't want to use trigger on INSERT (in my previous post i tell wrongly
> on update) becouse the behaviour of my application will be samething as
> - the service insert a block of same rows (for example 10k records)
> - for an interval of time from same seconds to same minutes (it is not a
> fixed interval) the table will not change
> - the service insert another block of rows...
> .....
>
> but what i want is to recalculate the view/second table only when the last
> row of the block is inserted (or equivalent when the transaction where
> them are isnrted has been committed).
>
> i hope that there's samething as view cached with the cache expiration
> wich depends on the modification of the table wich contains raw data,

As I said, this is called a "materialized view", something Firebird does not
(yet) support.


but your suggestion to use a secondary physical table wich will be updated
by my service after the rows insertion is ok too (and probably it will give
me a better/simpler application).
>

It's currently the only way to go ;-)

With regards,

Martijn Tonies
Upscene Productions
http://www.upscene.com

Download Database Workbench for Oracle, MS SQL Server, Sybase SQL
Anywhere, MySQL, InterBase, NexusDB and Firebird!

Database questions? Check the forum:
http://www.databasedevelopmentforum.com