Re: Replication

From: David Kerber <ns_dkerber_at_ids.net>
Date: Tue, 28 May 2002 15:36:14 -0400
Message-ID: <3CF3DC2E.77042956_at_ids.net>


How much data are you storing in the quote record itself? If it's just pointers to customer ID's, with the customer details stored in a different table, there's not much data being duplicated. Maintaining the pointers to the child records is a bit more work, but if you break up your quote info a bit more, you can handle it:

tblQuotes
QuoteID AutoInc
QuoteNum String (Your 1001-1, 1001-2, etc) SalesPerson Long
...
Other info as needed

tblQuoteDetails

QuoteID      Long
ItemID       Long
Qty          Integer

QuotedPrice Currency
...
Other info.

(with one record for each item on each quote)

Graham Bellamy wrote:
>
> "David Kerber" <ns_dkerber_at_ids.net> wrote in message news:3CF3B054.BD51137B_at_ids.net...

> > Another way to handle this might be to add a field to your quotes table
> > called something like Previous_Ver which contains just the pkey
> > reference to the previous version of this particular quote number.
> > Then you can walk the tree of previous_ver values from the most recent
> > to the original version of the quote, no matter how many revs it goes
> > through.
>
> Thanks. I think this should be able to be done with both methods I mentioned (1001,1007 &
> 1001-1, 1001-2).
>
> Any comments about the duplication of the entire record (and all its related child
> records)?
> In appreciation,
> Graham

-- 

Dave Kerber
Edit the return address by removing the ns_ before e-mailing

This message was entirely written using recycled electrons.

REAL programmers write self-modifying code, leading to: 
Why there is ALWAYS one more bug (courtesy of O.D. Williams):
   1.  Debuging code is  always much harder than writing it.
   2.  Therefore, if your code is as clever as you are capable of making
it, you are, by definition, inadequate to debug it.
Received on Tue May 28 2002 - 21:36:14 CEST

Original text of this message