> >Hopefully the other solution worked for how to parse the data. If not,
> >back. What I wanted to comment on is why would you use two tables, one
> >SHIP_TO and one for BILL_TO? Why not just add a column to one table set
> >it to BILL or SHIP. You won't be repeating data that way and it'll be
> >to find things overall. Plus you can just have a column that flags
> >the SHIP_TO and BILL_TO addresses are the same.
> I haven't gotten that far yet. BILL_TO and SHIP_TO aren't always
> the same people, hence my initial thought of creating two tables and
> keep things separate. However, you're right, I could dump it all into
> one table - if they're different, then populate the rest of the fields,
> if not, don't bother.
What I was thinking is that you have one table with
Flag -> Here you flag this as SHIP_TO or BILL_TO
Your order_ID could be a key, but it will not be unique, since if the
bill_to and ship_to address are different, the order_id will appear in the
table twice. So an order with different shipping and billing addresses would
have two rows in the table. An order where they are the same would only have
That layout would be better than:
Which is what I got from you last email.
Does anyone agree?
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php