PROPERTYDETAILTEMP

Stores stock detail information for a revenue records with a payment type of Stock

Fields

Field Field Type Null Notes Description
ID uniqueidentifier Default = (newid()) Primary Key.
PROPERTYSUBTYPECODEID uniqueidentifier yes FK to PROPERTYSUBTYPECODE
SALEDATE datetime yes The date to use when posting the sold property.
SALEAMOUNT money Default = 0 The price at which the property was sold.
BROKERFEE money Default = 0 The fee payed to the broker in the property sale.
SALEPOSTDATE datetime yes The date to use when posting the sold property record.
SALEPOSTSTATUSCODE tinyint Default = 1 Flag used to indicate whether sold property has been posted, should be posted or needs to be posted.
ADDEDBYID uniqueidentifier FK to CHANGEAGENT.
CHANGEDBYID uniqueidentifier FK to CHANGEAGENT.
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) yes CONVERT(bigint, TS) Numeric representation of the timestamp.
SALEPOSTSTATUS nvarchar(11) (Computed) yes CASE [SALEPOSTSTATUSCODE] WHEN 0 THEN N'Posted' WHEN 1 THEN N'Not Posted' WHEN 2 THEN N'Do Not Post' END Provides a translation for the 'SALEPOSTSTATUSCODE' field.
ORGANIZATIONSALEAMOUNT money Default = 0 The price at which the property was sold in the organization currency.
ORGANIZATIONBROKERFEE money Default = 0 The fee payed to the broker in the property sale in the organization currency.
TRANSACTIONSALEAMOUNT money Default = 0 The price at which the property was sold in the transaction currency.
TRANSACTIONBROKERFEE money Default = 0 The fee payed to the broker in the property sale in the transaction currency.
BASECURRENCYID uniqueidentifier yes The base currency associated with this record.
ORGANIZATIONEXCHANGERATEID uniqueidentifier yes The exchange rate used to convert to the organization amount.
TRANSACTIONCURRENCYID uniqueidentifier yes The transaction currency associated with this record.
BASEEXCHANGERATEID uniqueidentifier yes The exchange rate used to calculate the base amount.
ISSOLD int (Computed) case when SALEDATE is null then 0 else 1 end Indicates whether the property has sold or not.

Indexes

Index Name Fields Unique Primary Clustered
IX_PROPERTYDETAIL_DATEADDED DATEADDED yes

Triggers

Trigger Name Description
TR_PROPERTYDETAIL_T2BDELETE
TR_PROPERTYDETAIL_AUDIT_UPDATE
TR_PROPERTYDETAIL_AUDIT_DELETE
TR_PROPERTYDETAIL_INSERTUPDATE_CURRENCY