Friday, March 30, 2012

help on table design

Hi,
I need a table for the transactions, the transcation could
be credit card, check. they will have different data like
credit card has credit card number, and check have account
number, should I have separate table for each type? or put
them in one table? ThanksThis is a multi-part message in MIME format.
--=_NextPart_000_0183_01C3811B.1B861CE0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
As always, it depends. However, checking accounts and credit card =accounts are very different animals. A checking account could pay =interest but a credit card would not. A credit card has an expiry date. = A checking account does not. I'd be inclined to model these =separately. You can always use a UNION ALL to display the account =numbers in a single resultset.
-- Tom
---
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinnaclepublishing.com/sql
"Jen" <follower1999@.yahoo.com> wrote in message =news:060401c3813b$59a8e3c0$a301280a@.phx.gbl...
Hi,
I need a table for the transactions, the transcation could be credit card, check. they will have different data like credit card has credit card number, and check have account number, should I have separate table for each type? or put them in one table? Thanks
--=_NextPart_000_0183_01C3811B.1B861CE0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
&

As always, it depends. However, =checking accounts and credit card accounts are very different animals. A =checking account could pay interest but a credit card would not. A credit =card has an expiry date. A checking account does not. I'd be inclined =to model these separately. You can always use a UNION ALL to display =the account numbers in a single resultset.
-- Tom
---T=homas A. Moreau, BSc, PhD, MCSE, MCDBASQL Server MVPColumnist, SQL =Server ProfessionalToronto, ON Canadahttp://www.pinnaclepublishing.com/sql">www.pinnaclepublishing.com=/sql
"Jen" =wrote in message news:060401c3813b$59=a8e3c0$a301280a@.phx.gbl...Hi,I need a table for the transactions, the transcation could be credit =card, check. they will have different data like credit card has credit =card number, and check have account number, should I have separate table =for each type? or put them in one table? Thanks

--=_NextPart_000_0183_01C3811B.1B861CE0--

No comments:

Post a Comment