On Wed, Oct 19, 2011 at 5:31 AM, Rich Shepard <[email protected]> wrote:
> On Tue, 18 Oct 2011, Chris Travers wrote:
>
>> acc_trans.trans_id is a foreign key.  It references, in practice:
>> select id from ar
>> union
>> select id from ap
>> union
>> select id from gl;
>
> Chris,
>
>  I'm confused. Are you writing that the acc_trans.trans_id (the primary key
> on that table, I assume) consists strictly of foreign keys from ar, ap, and
> gl? Wow!

Hi Rich,

acc_trans.trans_id is foreign key indeed. There was no primary key on
acc_trans table. One was added by Chris 'entry_id' in LSMB 1.2.  I
added similar one in Ledger123 schema changes.

>  Does an update or deletion cascade from acc_trans to ar, ap, and gl?
CASCADE UPDATE OR DELETE is not there on any primary/foreign key and
it would work from the parent table only (ar, ap,gl).

Regards
Armaghan
_______________________________________________
SQL-Ledger mailing list
[email protected]
http://lists.ledger123.com/mailman/listinfo/sql-ledger

Reply via email to