Primary Key Field Type
 ID uniqueidentifier

Field Field Type Null Notes Description
 NAME nvarchar(256)   Default = '' Label/name of the image.
 DESCRIPTION nvarchar(256)   Default = '' Description of the image.
 FILENAME nvarchar(256)   Default = '' Name of file with extension
 UPLOADFILENAME nvarchar(256)   Default = '' Path, filename and extension of the originally uploaded file.
 IMAGETYPE nvarchar(50)   Default = '' Mime type of the image.
 IMAGESIZE int   Default = 0 Number of bytes in the image.
 IMAGECONTENT varbinary The serialized image file.
 CAPTION nvarchar(256)   Default = ''
 APPROVED bit   Default = 0 Flag to be used for needed approval.
 PRIVATE bit   Default = 0 Flag images only viewable by the participant.
 PHOTOGRAPHER nvarchar(256)   Default = '' Image creator.
 PHOTODATETAKEN datetime Date the photo was taken.
 TAGS nvarchar(256)   Default = '' Tags to assign photo, space separated.
 EXTERNALFLAG bit   Default = 0 Flags photos housed at external sources.
 IMAGESOURCECODE tinyint   Default = 0 Where the image was added from.
 IMAGESOURCE nvarchar(11) (Computed) CASE [IMAGESOURCECODE] WHEN 0 THEN N'FAF' WHEN 1 THEN N'Flickr' WHEN 2 THEN N'Photobucket' END Provides a translation for the 'IMAGESOURCECODE' field.
 EXTERNALURL nvarchar(256)   Default = '' URL to image if the image is not contained in the IMAGECONTENT.
 DATEADDED datetime   Default = getdate() Indicates the date this record was added.
 DATECHANGED datetime   Default = getdate() Indicates the date this record was last changed.
 TS timestamp   Timestamp.
 TSLONG bigint (Computed) CONVERT(bigint, TS) Numeric representation of the timestamp.

Foreign Key Field Type Null Notes Description
 CONSTITUENTID uniqueidentifier CONSTITUENT.LOCALID The image owner constituent id
 EVENTID uniqueidentifier EVENT.ID The event id related to this Image
 ADDEDBYID uniqueidentifier   CHANGEAGENT.ID FK to CHANGEAGENT.
 CHANGEDBYID uniqueidentifier   CHANGEAGENT.ID FK to CHANGEAGENT.

Index Name Field(s) Unique Primary Clustered
 IX_FAFIMAGES_CONSTITUENTID CONSTITUENTID      
 IX_FAFIMAGES_DATEADDED DATEADDED    
 IX_FAFIMAGES_DATECHANGED DATECHANGED      
 PK_FAFIMAGES ID  

Trigger Name Description
 TR_FAFIMAGES_AUDIT_UPDATE
 TR_FAFIMAGES_AUDIT_DELETE

Entity-Relationship diagram of this table