Re: Upgrade from 5.6 => 5.7

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Fri, 2011-09-16 at 00:56 +0800, Emmanuel Noobadmin wrote:

> So how do you retrieve data that are kept in different tables? Or do
> you simply replicate the same data in every single table that needs
> it?

No unnecessary replication because it wastes space and needs multiple
updates.  A customer number would be stored in an invoice header record
and in a customer name and address record. 

Data is generally stored once. However because of legal requirements a
customer's invoicing name and address and delivery address will be
copied from the customer file and permanently stored in an invoice's
header record. This means when the customer's record details are
changed, the invoice continues to show the original name and address
data valid at the time of creating that invoice.

Each table as a unique reference number.

A simple retrieval illustration ...

select * from p2 where p2ref = '$p1ref' ....

select p3surname, p3forename, p3add1, p3add2, p3add3, p3add4 (etc) from
p3 where p3customer = '$e7customer' ....

select w1note from w1 where w1date = '$s5date' ....



Paul.


_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos


[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux