At 04:44 PM 12/17/02 -0500, 1LT John W. Holmes wrote:
What I was thinking is that you have one table with
Order_ID
Name
Address
Flag -> Here you flag this as SHIP_TO or BILL_TO
etc...
That layout would be better than:
Order_ID
Ship_name
Ship_address
Bill_name
Bill_address
etc...
Which is what
*
-Original Message-
From: Brad Bonkoski [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 17, 2002 3:50 PM
To: 1LT John W. Holmes
Cc: [EMAIL PROTECTED]; PHP-General List
Subject: Re: [PHP] key pairs
What about a master table like:
Order ID | Ship_TO | BILL_TO
Then an address table:
ID
What about a master table like:
Order ID | Ship_TO | BILL_TO
Then an address table:
ID | NAME | ADDR | CITY | STATE | ZIP
Then you could have many addresses, and IFFthe Bill to and Ship to were the same
then the master table would reflect that. Many sites provide a check box to
indicate that th
> >Hopefully the other solution worked for how to parse the data. If not,
post
> >back. What I wanted to comment on is why would you use two tables, one
for
> >SHIP_TO and one for BILL_TO? Why not just add a column to one table set
set
> >it to BILL or SHIP. You won't be repeating data that way and
1LT John W. Holmes wrote:
Hopefully the other solution worked for how to parse the data. If not, post
back. What I wanted to comment on is why would you use two tables, one for
SHIP_TO and one for BILL_TO? Why not just add a column to one table set set
it to BILL or SHIP. You won't be repeating d
CTED]>
Sent: Tuesday, December 17, 2002 3:15 PM
Subject: [PHP] key pairs
>
> I have the following bit of information coming in that I need to
> generate key pairs of so I can drop it all into a database. I'm
> creating tables for each section (SHIP_TO and BILL_TO) with m
TED]>
To: Tim Ward <[EMAIL PROTECTED]>
Cc: PHP-General List <[EMAIL PROTECTED]>
Sent: Tuesday, December 17, 2002 8:25 PM
Subject: Re: [PHP] key pairs
> Tim Ward wrote:
>
> >1. Have an order_id on the first table (or a separate
> >ORDER table) that is INT and AUTO_
This is a bit crude but should work:
Note that I made a bunch of assumptions here--that the data is always
properly formatted, that there is only one record in the $data, and that
you will later manipulate the key names so that they will actually work
as database columns. Still, this way you can
Tim Ward wrote:
1. Have an order_id on the first table (or a separate
ORDER table) that is INT and AUTO_INCREMENT.
2. Have an order_id on the other table(s) that is INT but
not AUTO_INCREMENT.
3. Create the record in the first table just inserting the info
you get in.
4. get the order_id just
2002 8:15 PM
Subject: [PHP] key pairs
>
> I have the following bit of information coming in that I need to
> generate key pairs of so I can drop it all into a database. I'm
> creating tables for each section (SHIP_TO and BILL_TO) with matching
> Unique_IDs. What's th
I have the following bit of information coming in that I need to
generate key pairs of so I can drop it all into a database. I'm
creating tables for each section (SHIP_TO and BILL_TO) with matching
Unique_IDs. What's the best way to go about this (creating the pairs,
stripping off excess
11 matches
Mail list logo