Reply to Re: Tables as Three-Dimensional Arrays

Your name:

Reply:


Posted by Ken Chau on 01/31/06 08:23

Well, that sounds like a classic case of normalized tables with a
foreign key pointing to a different table:

create table products (
id int primary key auto_increment,
product_number int
);

create table quantity_costs (
id int primary key auto_increment,
product_id int,
cost float,
quantity int
);

a simple query as below will get you your costs:

select * from products p, quantity_costs c where p.id = c.product_id;

------------

Ken Chau
http://www.gizzar.com

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация