subaccounts

G

G

I am working on a asset database and was wondering the best way to create
Main - sub - sub accounts for the types of assets?
 
S

Steve

TblAssetAccount
AssetAccountID
AssetAccount

TblAssetSubAccount
AssetSubAccountID
AssetAccountID
AssetSubAccount

TblAssetSubSubAccount
AssetSubSubAccountID
AssetSubAccountID
AssetSubSubAccount


Steve
 
G

G

Thanks, G.

Steve said:
TblAssetAccount
AssetAccountID
AssetAccount

TblAssetSubAccount
AssetSubAccountID
AssetAccountID
AssetSubAccount

TblAssetSubSubAccount
AssetSubSubAccountID
AssetSubAccountID
AssetSubSubAccount


Steve
 
J

John... Visio MVP

G said:
I am working on a asset database and was wondering the best way to create
Main - sub - sub accounts for the types of assets?


What do you really need? Is it a unique account number for an asset that has
several layers? A main account number containing a sub account number that
could contain further divisions. In that case, the asset needs a unique key
and should have secondary keys for the account, sub account and sub-sub
account.

John... Visio MVP
 
G

Graham Mandeno

Hi G

I think Steve's suggestion is rather inflexible. What if you need more than
three levels? What if you want to reclassify an account as being somewhere
else in the hierarchy?

I would favour a structure something like this:

AccID (primary key)
AccName
AccParent (null for top-level accounts, otherwise the ID of the parent)
AccOrder (the numeric order that the account should be listed among its
siblings)
AccPostable (boolean - whether or not transactions may be posted to this
account [false for an account that is only a header])
 
K

Klatuu

Go with Graham's method. It is much better.
As Graham said, the other suggestion, although workable, is inflexible.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top