Re: [PATCH 01/34] Introduce new SQL schema.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Feb 03, 2008 at 01:37:30PM +0100, Holger Eitzenberger wrote:
> Eric Leblond <eric@xxxxxx> writes:
> 
> >> and what about sqlite3?
> >
> > I don't think sqlite3 will be able to support SQL things used in this
> > schema. Holger, do you confirm that ?
> 
> AFAIK sqlite3 does not have stored procedures as other databases have,
> instead you can use triggers with somewhat limited functionality
> compared to stored procedures.  Alternatively you can write extensions
> in plain C, but those may not be what you need.
> 
> Does your change optimize DB memory consumption or is it targeted at
> improving access times?

Hi,

The new SQL schema has the following advantages:

 - storage: split packets into several tables (instead of one big
   table). This can help a lot on storage efficiency, depending on the
   DB

 - indexes: many indexes were missing

 - SQL schema independence: stored procedures and views are used to
   ensure the C code does not have to know how SQL data are stored. This
   abstraction layer allows to change the SQL layout without changing
   the C code

 - extensibility: a unique ID is used as a relation between tables. This
   way, a third-party application can create tables to add information,
   without changing the default SQL schema.
   Foreign keys are used to ensure consistency.

The main idea was to introduce this abstraction layer to "hide"
insertions into multiple tables. Unfortunately, I'm not sure how to
handle this with sqlite ..
Using stored procedures may improve access times by preparing the query
once (sort of compilation) and executing it faster, though this is not
the first objective.
Using several tables will mostly help for read access.

Regards,
Pierre
-
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux