[Monetdb-developers] commit options for create table statement....
![](https://secure.gravatar.com/avatar/f3e0ee2587d8882de40d601ca1a30d47.jpg?s=120&d=mm&r=g)
Reading the MonetDB code seems that commit option ON COMMIT DROP ON COMMIT PRESERVE ROWS ON COMMIT DELETE ROWS
should not be used for normal tables (the ones which are not temporary). If that is the rule, the commit option should be allowed in the create table statement. If it is not the rule, the commit option is not being used at all for the normal tables.
Look to the following example (auto-commit mode is on):
CREATE TABLE test1(id int) ON COMMIT DELETE ROWS;
&3
insert into test1 values(1);
&2 1 -1
select * from test1;
&1 3 1 1 1 % sys.test1 # table_name % id # name % int # type % 1 # length [ 1 ]
So what is the rule for MonetDB?
Regards, Romulo
![](https://secure.gravatar.com/avatar/fef2c36212357b81f48efe7e25cfbf5c.jpg?s=120&d=mm&r=g)
On Sat, Jan 05, 2008 at 07:35:58PM +0100, Romulo Goncalves wrote:
Reading the MonetDB code seems that commit option ON COMMIT DROP ON COMMIT PRESERVE ROWS ON COMMIT DELETE ROWS
should not be used for normal tables (the ones which are not temporary). If that is the rule, the commit option should be allowed in the create table statement. If it is not the rule, the commit option is not being used at all for the normal tables.
Look to the following example (auto-commit mode is on):
CREATE TABLE test1(id int) ON COMMIT DELETE ROWS;
&3
insert into test1 values(1);
&2 1 -1
select * from test1;
&1 3 1 1 1 % sys.test1 # table_name % id # name % int # type % 1 # length [ 1 ]
So what is the rule for MonetDB?
on commit actions are only defined for temporary tables! This is a sql specification. Afcourse we could allow it and simply see persistent tables + commit action as global temps.
Niels
Regards, Romulo
This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Monetdb-developers mailing list Monetdb-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-developers
participants (2)
-
Niels Nes
-
Romulo Goncalves