Re: [GENERAL] keeping 3 tables in sync w/ each other

2007-09-19 Thread Ow Mun Heng
On Wed, 2007-09-19 at 19:31 +0800, Ow Mun Heng wrote: > On Wed, 2007-09-19 at 11:05 +0100, Filip Rembiałkowski wrote: > > 2007/9/19, Ow Mun Heng <[EMAIL PROTECTED]>: > > > > (...) > > > > > simulate a delete > > > => delete from parent where id in (select id from child); > > > DELETE 6 > > > > >

Re: [GENERAL] keeping 3 tables in sync w/ each other

2007-09-19 Thread Ow Mun Heng
On Wed, 2007-09-19 at 11:05 +0100, Filip Rembiałkowski wrote: > 2007/9/19, Ow Mun Heng <[EMAIL PROTECTED]>: > > (...) > > > simulate a delete > > => delete from parent where id in (select id from child); > > DELETE 6 > > > > => select * from parent; > > id | data1 > > +- > > 2 | p

Re: [GENERAL] keeping 3 tables in sync w/ each other

2007-09-19 Thread Filip Rembiałkowski
2007/9/19, Ow Mun Heng <[EMAIL PROTECTED]>: (...) > simulate a delete > => delete from parent where id in (select id from child); > DELETE 6 > > => select * from parent; > id | data1 > +- > 2 | parent2 > 3 | parent3 > 4 | parent4 > > => select * from child; > id | data1 > ---

Re: [GENERAL] keeping 3 tables in sync w/ each other

2007-09-19 Thread Ow Mun Heng
On Tue, 2007-09-18 at 08:37 -0400, [EMAIL PROTECTED] wrote: > Ow Mun Heng wrote: > > Hi, > > > > create table foo (a int, b int, c int) > > create table foo_loading_source1 (a int, b int, c int) > > create table foo_loading_source2 (a int, b int, c int) > > > > Is there a way which can be made easi

Re: [GENERAL] keeping 3 tables in sync w/ each other

2007-09-19 Thread Ow Mun Heng
On Tue, 2007-09-18 at 09:56 +0100, Filip Rembiałkowski wrote: > 2007/9/18, Ow Mun Heng <[EMAIL PROTECTED]>: > > Hi, > > > > I have 3 tables > > > > foo > > foo_loading_source1 > > foo_loading_source2 > > > > which is something like > > > > create table foo (a int, b int, c int) > > create table foo

Re: [GENERAL] keeping 3 tables in sync w/ each other

2007-09-18 Thread Sascha Bohnenkamp
> Can I use inheritance? References? inheritance ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings

Re: [GENERAL] keeping 3 tables in sync w/ each other

2007-09-18 Thread btober
Ow Mun Heng wrote: Hi, I have 3 tables foo foo_loading_source1 foo_loading_source2 which is something like create table foo (a int, b int, c int) create table foo_loading_source1 (a int, b int, c int) create table foo_loading_source2 (a int, b int, c int) Is there a way which can be made eas

Re: [GENERAL] keeping 3 tables in sync w/ each other

2007-09-18 Thread Filip Rembiałkowski
2007/9/18, Ow Mun Heng <[EMAIL PROTECTED]>: > Hi, > > I have 3 tables > > foo > foo_loading_source1 > foo_loading_source2 > > which is something like > > create table foo (a int, b int, c int) > create table foo_loading_source1 (a int, b int, c int) > create table foo_loading_source2 (a int, b int,

[GENERAL] keeping 3 tables in sync w/ each other

2007-09-17 Thread Ow Mun Heng
Hi, I have 3 tables foo foo_loading_source1 foo_loading_source2 which is something like create table foo (a int, b int, c int) create table foo_loading_source1 (a int, b int, c int) create table foo_loading_source2 (a int, b int, c int) Is there a way which can be made easier to keep these 3 t