Not sure how to approach this
From: <jctown_at_nb.sympatico.ca>
Date: 3 Sep 2006 08:57:03 -0700
Message-ID: <1157299023.379204.29200_at_h48g2000cwc.googlegroups.com>
[Quoted] I have 3 tables.
Date: 3 Sep 2006 08:57:03 -0700
Message-ID: <1157299023.379204.29200_at_h48g2000cwc.googlegroups.com>
[Quoted] I have 3 tables.
[Quoted] 1) books [Quoted] 2) publishers [Quoted] 3) subjects
I *think* I need to use a trigger but not sure. I've loaded up publishers with distinct publisher from books and subjects from distinct subject from books. Now I want to set *something* up so that if I add a new row to "books" a check will be made on publishers and subjects to see if something new is being added and then add a row if this is the case.
Something like
On_New_Book
insert into publishers
select publisher from book where book.publisher not in (select publisher from book) insert into subjects select subject from book where book.subject not in (select subject from book)
I don't know how close or far away I am. I'm not even sure if a "trigger" is what I need here. Received on Sun Sep 03 2006 - 17:57:03 CEST