This is an old revision of the document!


Description

The Account Schema is the logical relationship between tables in a Control database that deal with Customers and Contacts.

  • Account
    • AccountContact

linked on Account.ID = AccountContact.AccountID

backlink on Account.PrimaryContactID = AccountContact.ID

backlink on Account.BillingContactID = AccountContact.ID

  • AccountContactUserField

>> linked on AccountContact.ID = AccountContactUserField.ID

  • Address

>> linked on AccountContact.BillingAddressID = Address.ID

>> linked on AccountContact.ShippingAddressID = Address.ID

  • AddressLink

>> linked on AccountContact.ID = AddressLink.ParentID and AccountContact.ClassTypeID = AddressLink.ParentClassTypeID

  • Address

>>> linked on AddressLink.AddressID = Address.ID

  • PhoneNumber

>> linked on AccountContact.MainPhoneNumberID = PhoneNumber.ID

>> linked on AccountContact.MainFaxNumberID = PhoneNumber.ID

  • Employee (used when using separate sales people for contacts)

>> linked on Account.SalespersonID1 = Employee.ID

>> linked on Account.SalespersonID2 = Employee.ID

>> linked on Account.SalespersonID3 = Employee.ID

  • AccountUserField

> linked on Account.ID = AccountUserField.ID

  • Address

> linked on AccountContact.BillingAddressID = Address.ID

> linked on AccountContact.ShippingAddressID = Address.ID

  • AddressLink

> linked on Account.ID = AddressLink.ParentID and Account.ClassTypeID = AddressLink.ParentClassTypeID

  • Address

>> linked on AddressLink.AddressID = Address.ID

  • PhoneNumber

> linked on Account.MainPhoneNumberID = PhoneNumber.ID

> linked on Account.MainFaxNumberID = PhoneNumber.ID

  • PricingLevel

> linked on Account.PricingLevelID = PricingLevel.ID

  • Promotion

> linked on Account.PromotionID = Promotion.ID

  • PaymentTerms

> linked on Account.PaymentTermsID = PaymentTerm.ID

  • TaxClass

> linked on Account.ClassTypeID = ClassType.ID

  • Employee

> linked on Account.SalespersonID1 = Employee.ID

> linked on Account.SalespersonID2 = Employee.ID

> linked on Account.SalespersonID3 = Employee.ID

  • Account (self-reference for parent/subsidiaries)

> linked on Account.ParentID = Account.ID

=Source=

Contributor: Cyrious

Date: 6/2016

Version: Control 5/7

You could leave a comment if you were logged in.