A discussion about the Notes table and TableIDs

1 minute read time.
In several areas of the system you will see references to Table ID. This is especially true if you are programming directly using the Record or Query Objects.

The notes table is quite straightforward. You can add a notes table onto just about any entity, for example company (already there) or communication. The columns in the table are:

Note_NoteId
*Note_ForeignTableId
*Note_ForeignId

Note_Note
Note_CreatedBy
Note_CreatedDate
Note_UpdatedBy
Note_UpdatedDate
Note_TimeStamp
Note_Deleted
Note_SegmentID
Note_ChannelID

The ones asterisked are the relevant ones for coding and linking to entities.
Note_ForeignTableId, contains the internal ID of the parental table.
Note_ForeignTableId, contains the Unique ID of the parental record.

So if linked to 3G Homes, then the note will have

*Note_ForeignTableId = 5
*Note_ForeignId = 43

The values for Note_ForeignTableId are not documented directly. These are from the custom_tables Meta Data table and the bord_tableid field. These values are listed in the System Administrator Guide in the discussion of table locking.

ID --- Table
1 --- Address
2 --- CaseProgress
3 --- Cases
4 --- Communication
5 --- Company
6 --- Email
7 --- Library
8 --- Marketing
9 --- Notes
10 --- Opportunity
11 --- OpportunityItem
12 --- OpportunityProgress
13 --- Person
14 --- Phone
15 --- Products
17 --- Team
  • FormerMember
    FormerMember

    Hi Jeff,

    I am creating notes trhough the self service and I am unable to set a certain userid as the created by id,

    The idea is to use a resource user with the name "logged from Selfservice".

    Is it possible to acomplish this? do I have to make use of a table script for the null values?