Contact Fields
The following field information is intended assist those who design reports for Sage 50 using Crystal Reports.
Filename: CONTACTS.DAT
Contacts.DAT is the contact file. It contains a row (record) for each contact. Most of the information below is entered or displayed in Sage 50's Maintain Customers/Prospects> Contact tab.
- To add Sage 50 contact fields to your Crystal reports, select CONTACTS.DAT.
Indexes and Their Uses
CONTACTS.DAT has 3 keys, as follows:
0 = ByContactRecordNum
1 = ByGuid
2 = ByCustRecordNumber
Fields
The following table shows the fields available in the CONTACTS.DAT file and includes the type and size in number of bytes of each field.
Field Name |
Type |
Size |
Comment |
---|---|---|---|
RecordNumber |
Integer |
4 |
Identity value. Primary key for the table. This value is not visible on the Contacts tab. |
Guid |
Binary |
16 |
(Globally Unique Identifier) Unique identifier for the contact. It is used for linking the contact to other tables. This value is not visible on the Contacts tab. |
LastName |
ZString |
20 |
Contact's last name |
FirstName |
ZString |
15 |
Contact's first name |
MiddleInitial |
ZString |
1 |
Contact's middle initial (without the period) |
Prefix |
ZString |
4 |
Contact's prefix designation (e.g. Ms., Mr. |
Suffix |
ZString |
4 |
Contact's suffix (e.g. Jr. |
Gender |
Integer |
2 |
0=unspecified 1=male 2=female |
Title |
ZString |
30 |
The contact's job title. |
CompanyName |
ZString |
39 |
The company name associated with the contact |
Telephone1 |
ZString |
20 |
The Telephone 1 value from the Contacts tab. |
Telephone2 |
ZString |
20 |
The Telephone 2 value from the Contacts tab. |
Fax |
ZString |
20 |
The Fax number from the Contacts tab. |
|
ZString |
64 |
The email address from the Contacts tab. |
Notes |
ZString |
255 |
Any notes that were entered for the contact |
AddressRecordNumber |
Integer |
4 |
A foreign key to the Address record assigned to this contact. This column matches up to the Address.AddressRecordNumber column. |
CustomerRecord |
Integer |
4 |
A foreign key back to the Customer record. It associates a customer record with the contact. This column matches the Customer.CustomerRecordNumber column. |
IsPrimaryContact |
Integer |
1 |
0 = false. This contact is not the primary or bill-to contact. 1 = true. This contact is the primary or bill-to contact. Note: Only one contact for each customer can be the primary or bill-to contact. |
IsDefaultShipTo |
Integer |
1 |
0 = false. This contact is not the default ship-to contact. 1 = true. This contact is the default ship-to contact. Note: Only one contact for each customer can be the default ship-to contact. |
NameToUseOnForms |
Integer |
2 |
0 = use the full contact name when a contact name is required. 1 = use the company name associated with the contact when a contact name is required. |