ERP/2.50/Developers Guide/Database Model/org.openbravo.model.ad.datamodel/AD Column
AD_Column
Defines the columns of a table
The Used in Column Tab defines the table and column this element resides in.
- Name:ADColumn
- Classname:Column
This table contains the following columns:
Name | Nullable | Data Type | Description |
AD_Column_ID | N | VARCHAR2(32) | A link to the database column of the table. |
AD_Client_ID | N | VARCHAR2(32) | Client for this installation. |
AD_Org_ID | N | VARCHAR2(32) | Organizational entity within client |
IsActive | N | CHAR(1) | A flag indicating whether this record is available for use or de-activated. |
Created | N | DATE | The date that this record is completed. |
Updated | N | DATE | x not implemented |
CreatedBy | N | VARCHAR2(32) | User who created this records |
UpdatedBy | N | VARCHAR2(32) | User who updated this records |
Name | N | NVARCHAR2(60) | A non-unique identifier for a record/document often used as a search tool. |
Description | Y | NVARCHAR2(255) | A space to write additional related information. |
Help | Y | NVARCHAR2(2000) | A comment that adds additional information to help users work with fields. |
ColumnName | N | VARCHAR2(40) | The name of a column within the database. |
AD_Table_ID | N | VARCHAR2(32) | A dictionary table used for this tab that points to the database table. |
AD_Reference_ID | N | VARCHAR2(32) | The data type of this field. |
AD_Reference_Value_ID | Y | VARCHAR2(32) | The exact reference specification for a list or a table. |
AD_Val_Rule_ID | Y | VARCHAR2(32) | A validation rule that defines how an entry is determined to be valid or invalid. |
FieldLength | N | NUMBER(10, 0) | An indication of the column length as defined in the database. |
DefaultValue | Y | NVARCHAR2(2000) | The first non-null value in a set of values. It is used as a default value for a field when creating a record. |
IsKey | N | CHAR(1) | This column is the key in this table |
IsParent | N | CHAR(1) | This column is a link to the parent table (e.g. header from lines) - incl. Association key columns |
IsMandatory | N | CHAR(1) | An indication noting that completing in a field is required to proceed. |
IsUpdateable | N | CHAR(1) | An indication that an item can be updated by the user. |
ReadOnlyLogic | Y | NVARCHAR2(2000) | Logic to determine if field is read only (applies only when field is read-write) |
IsIdentifier | N | CHAR(1) | This column is part of the record identifier |
SeqNo | Y | NUMBER(10, 0) | The order of records in a specified document. |
IsTranslated | N | CHAR(1) | An indication that an item is translated. |
IsEncrypted | N | CHAR(1) | An indication noting if the input box of a field will present full text or just asterisks. |
Callout | Y | NVARCHAR2(60) | A series of actions that occur when data is modified. |
VFormat | Y | NVARCHAR2(60) | x not implemented |
ValueMin | Y | NVARCHAR2(20) | The lowest possible value an object can take. |
ValueMax | Y | NVARCHAR2(20) | The highest possible value an item can have. |
IsSelectionColumn | N | CHAR(1) | Is this column used for finding rows in windows |
AD_Element_ID | Y | VARCHAR2(32) | An element that consolidates help, descriptions and terms for a database column and allows for a central maintenance. |
AD_Process_ID | Y | VARCHAR2(32) | A series of actions carried out in sequential order. |
IsSessionAttr | Y | CHAR(1) | Is session attribute |
IsSecondaryKey | Y | CHAR(1) | Is secondary key |
IsDesencryptable | Y | CHAR(1) | Is desencryptable |
AD_Callout_ID | Y | VARCHAR2(32) | A series of actions that occur when data is modified. |
Developmentstatus | Y | VARCHAR2(60) | Development Status |
AD_Module_ID | N | VARCHAR2(32) | Module |
Position | Y | NUMBER | Determines the physical column position |
IsTransient | Y | CHAR(1) | Mark if a column is transient and will be ignored when comparing data |
isTransientCondition | Y | VARCHAR2(2000) | Java expression that will be evaluated and if the result is false, the column will be marked as transient |
Isautosave | N | CHAR(1) | Defines if a button triggers autosave or not |
ValidateOnNew | N | CHAR(1) | Validations and callouts are executed when a new record is created. |
Other Info
Check constraints
These are the check constraints for this table:
- AD_COLUMN_ISACTIVE_CHK: ISACTIVE IN ('Y', 'N')
- AD_COLUMN_ISAUTOSAVE_CHK: ISAUTOSAVE IN ('Y', 'N')
- AD_COLUMN_ISDESENCRYPTABLE_CHK: ISDESENCRYPTABLE IN ('Y', 'N')
- AD_COLUMN_ISENCRYPTED_CHK: ISENCRYPTED IN ('Y', 'N')
- AD_COLUMN_ISIDENTIFIER_CHK: ISIDENTIFIER IN ('Y', 'N')
- AD_COLUMN_ISKEY_CHK: ISKEY IN ('Y', 'N')
- AD_COLUMN_ISMANDATORY_CHK: ISMANDATORY IN ('Y', 'N')
- AD_COLUMN_ISPARENT_CHK: ISPARENT IN ('Y', 'N')
- AD_COLUMN_ISSELECTIONCOLUM_CHK: ISSELECTIONCOLUMN IN ('Y', 'N')
- AD_COLUMN_ISTRANSLATED_CHK: ISTRANSLATED IN ('Y', 'N')
- AD_COLUMN_ISUPDATEABLE_CHK: ISUPDATEABLE IN ('Y', 'N')
Indexes
These are the indexes for this table (for each index there is a list of all the columns included within it):
Non Unique
- AD_COLUMN_TABLE
Unique
- AD_COLUMN_KEY
- AD_COLUMN_NAME
- AD_COLUMN_NAME_AD_TABLE
Columns
Column
Link to the database column of the table
- Physical column name: AD_Column_ID
- Property Name: id
- Reference: ID
Client
- Physical column name: AD_Client_ID
- Property Name: client
- Reference: TableDir
- Default value: @AD_CLIENT_ID@
Foreign key column to AD_Client table, (column: AD_Client_ID)
Validation Rule AD_Client Security validation: Clients with user access rights. With the following code:
AD_Client.AD_Client_ID IN (@#User_Client@)
Organization
- Physical column name: AD_Org_ID
- Property Name: organization
- Reference: TableDir
- Default value: @AD_Org_ID@
Foreign key column to AD_Org table, (column: AD_Org_ID)
Active
There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reporting. There are two reasons for de-activating and not deleting records:
(1) The system requires the record for auditing purposes.
(2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are existing invoices for it. By de-activating the Business Partner you prevent it from being used in future transactions.
- Physical column name: IsActive
- Property Name: active
- Reference: YesNo
- Default value: Y
Creation Date
The Created field indicates the date that this record was created.
- Physical column name: Created
- Property Name: creationDate
- Reference: DateTime
Updated
The Updated field indicates the date that this record was updated.
- Physical column name: Updated
- Property Name: updated
- Reference: DateTime
Created By
- Physical column name: CreatedBy
- Property Name: createdBy
- Reference: Search
Foreign key column to AD_User table, (column: AD_User_ID)
Updated By
- Physical column name: UpdatedBy
- Property Name: updatedBy
- Reference: Search
Foreign key column to AD_User table, (column: AD_User_ID)
Name
A more descriptive identifier (that does need to be unique) of a record/document that is used as a default search option along with the search key (that is unique and mostly shorter). It is up to 60 characters in length.
- Physical column name: Name
- Property Name: name
- Reference: String
Description
A description is limited to 255 characters.
- Physical column name: Description
- Property Name: description
- Reference: String
Help/Comment
The Help field contains a hint, comment or help about the use of this item.
- Physical column name: Help
- Property Name: helpComment
- Reference: Text
DB Column Name
The Column Name indicates the name of a column on a table as defined in the database.
- Physical column name: ColumnName
- Property Name: dBColumnName
- Reference: String
- This column is part of the table's identifier
Table
- Physical column name: AD_Table_ID
- Property Name: table
- Reference: TableDir
- This column is a child for a buisiness object (is Parent)
Foreign key column to AD_Table table, (column: AD_Table_ID)
Reference
- Physical column name: AD_Reference_ID
- Property Name: reference
- Reference: Table
Foreign key column to AD_Reference table, (column: AD_Reference_ID)
Reference Table AD_Reference Data Types With the following where clause:
AD_Reference.IsBaseReference='Y'
Reference Search Key
- Physical column name: AD_Reference_Value_ID
- Property Name: referenceSearchKey
- Reference: Table
Foreign key column to AD_Reference table, (column: AD_Reference_ID)
Reference Table AD_Reference Subreferences : (not DataType and Independent). With the following where clause:
AD_Reference.IsBaseReference = 'N'
Validation Rule AD_Reference Subreference: Subreference validation choices. With the following code:
AD_Reference.ParentReference_ID=@AD_Reference_ID@ OR (@AD_Reference_ID@ = '28' AND AD_Reference.ParentReference_ID='17')
Validation
- Physical column name: AD_Val_Rule_ID
- Property Name: validation
- Reference: TableDir
Foreign key column to AD_Val_Rule table, (column: AD_Val_Rule_ID)
Length
The Length indicates the length of a column as defined in the database.
- Physical column name: FieldLength
- Property Name: length
- Reference: Integer
Default Value
The defaults are evaluated in the order of definition, the first not null value becomes the default value of the column. The values are separated by comma or semicolon. a) Literals:. 'Text' or 123 b) Variables - in format @Variable@ - Login e.g. #Date, #AD_Org_ID, #AD_Client_ID - Accounting Schema: e.g. $C_AcctSchema_ID, $C_Calendar_ID - Global defaults: e.g. DateFormat - Window values (all Picks, CheckBoxes, RadioButtons, and DateDoc/DateAcct) c) SQL code with the tag: @SQL=SELECT something AS DefaultValue FROM ... The SQL statement can contain variables. There can be no other value other than the SQL statement. The default is only evaluated, if no user preference is defined. Default definitions are ignored for record columns as Key, Parent, Client as well as Buttons.
- Physical column name: DefaultValue
- Property Name: defaultValue
- Reference: Text
Key Column
The key column must also be display sequence 0 in the field definition and may be hidden.
- Physical column name: IsKey
- Property Name: keyColumn
- Reference: YesNo
Callout: SL_Column
This element is linked to a callout.
It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Column Java class.
Link to Parent Column
The Parent checkbox indicates if this column is a link to the parent table.
- Physical column name: IsParent
- Property Name: linkToParentColumn
- Reference: YesNo
Mandatory
The Mandatory checkbox indicates if the field is required for a record to be save to the database.
- Physical column name: IsMandatory
- Property Name: mandatory
- Reference: YesNo
Updatable
The Updateable checkbox indicates if a field can be updated by the user.
- Physical column name: IsUpdateable
- Property Name: updatable
- Reference: YesNo
- Default value: Y
Read Only Logic
Logic to determine if field is read only (applies only when field is read-write)
- Physical column name: ReadOnlyLogic
- Property Name: readOnlyLogic
- Reference: Text
Identifier
The Identifier checkbox indicates that this column is part of the identifier or key for this table
- Physical column name: IsIdentifier
- Property Name: identifier
- Reference: YesNo
Sequence Number
The Sequence indicates the order of records
- Physical column name: SeqNo
- Property Name: sequenceNumber
- Reference: Integer
- Default value: @SQL=SELECT COALESCE(MAX(SeqNo),0)+10 AS DefaultValue FROM AD_Column WHERE AD_Table_ID=@AD_Table_ID@
Translation
The Translated checkbox indicates if this column is translated.
- Physical column name: IsTranslated
- Property Name: translation
- Reference: YesNo
Display Encription
Display encryption - all characters are displayed as '*'. Data storage encryption (i.e. you will not be able to report the data via report tools) is set in the Column definition.
- Physical column name: IsEncrypted
- Property Name: displayEncription
- Reference: YesNo
Callout Function
Function Calls separated by semicolons; SE_/SL_/UE_/UL_ - 1st: System/User; 2nd: Enter/Leave; 3rd: _ Underscore, - then Function Name
- Physical column name: Callout
- Property Name: calloutFunction
- Reference: String
Value Format
Value Format is the format the value will be displayed with.
- Physical column name: VFormat
- Property Name: valueFormat
- Reference: String
Min. Value
The Minimum Value indicates the lowest allowable value for a field.
- Physical column name: ValueMin
- Property Name: minValue
- Reference: String
Max. Value
The Maximum Value indicates the highest allowable value for a field
- Physical column name: ValueMax
- Property Name: maxValue
- Reference: String
Filter Column
If selected, this column will be used in the Search Window as an available filter criteria.
- Physical column name: IsSelectionColumn
- Property Name: filterColumn
- Reference: YesNo
Application Element
- Physical column name: AD_Element_ID
- Property Name: applicationElement
- Reference: TableDir
- This column is a child for a buisiness object (is Parent)
Foreign key column to AD_Element table, (column: AD_Element_ID)
Process
- Physical column name: AD_Process_ID
- Property Name: process
- Reference: TableDir
Foreign key column to AD_Process table, (column: AD_Process_ID)
Stored in Session
Checking this field the data for this column will be stored as session attribute so its content will be accessible from other tab.
- Physical column name: IsSessionAttr
- Property Name: storedInSession
- Reference: YesNo
Secondary Key
Is secondary key
- Physical column name: IsSecondaryKey
- Property Name: secondaryKey
- Reference: YesNo
- Default value: N
De-encryptable
When Is Desencryptable field is 'Y' the content of this column will be saved in a desencryptable way.
- Physical column name: IsDesencryptable
- Property Name: deencryptable
- Reference: YesNo
- Default value: N
Callout
- Physical column name: AD_Callout_ID
- Property Name: callout
- Reference: TableDir
Foreign key column to AD_Callout table, (column: AD_Callout_ID)
Development Status
Development Status defines the status of a table or a column. Ready means that this object is in use, Not Implemented Yet indicates that currently it is not in use but it is planned to be implemented and Deprecated are the objects that are going to be removed from the application in future versions.
- Physical column name: Developmentstatus
- Property Name: developmentStatus
- Reference: List
- Default value: RE
List values: Development Status
The allowed values for this list are:
- CC (Custom Code)
- DP (Deprecated)
- NI (Not Implemented Yet)
- RE (Ready)
Module
- Physical column name: AD_Module_ID
- Property Name: module
- Reference: TableDir
- Default value: @SQL=SELECT P.AD_MODULE_ID FROM AD_PACKAGE P, AD_TABLE T WHERE AD_TABLE_ID = @AD_Table_ID@ AND P.AD_PACKAGE_ID = T.AD_PACKAGE_ID
Foreign key column to AD_Module table, (column: AD_Module_ID)
Validation Rule Ad_Module_ID IsInDevelopment: AD_Module_ID IsInDevelopment. With the following code:
IsInDevelopment = 'Y' AND type != 'T'
Position
Determines the physical column position in database. It is a mandatory field which value is unique for all the columns within the same table.
- Physical column name: Position
- Property Name: position
- Reference: Integer
Transient
Mark if a column is transient and will be ignored when comparing data
- Physical column name: IsTransient
- Property Name: transient
- Reference: YesNo
- Default value: N
Transient Condition
Java expression that will be evaluated and if the result is false, the column will be marked as transient
- Physical column name: isTransientCondition
- Property Name: transientCondition
- Reference: Text
Isautosave
If the value is 'Y' the autosave flag will be put in the form and the Autosave process will be triggered
- Physical column name: Isautosave
- Property Name: isautosave
- Reference: YesNo
- Default value: Y
Validate on New
Indicates whether validations and callouts are executed when a new record is created. In general is should be set to Y. It makes sense to disable only in case there are callouts or validations associated to this column and it is known that when a new record is created they do not change any value; in this case this check allows to bypass their execution improving performance.
- Physical column name: ValidateOnNew
- Property Name: validateOnNew
- Reference: YesNo
- Default value: Y
Related tables
Tables that link this table:
- ADChangeLog.Column
- ADColumnAccess.Column
- ADField.Column
- ADReferencedTable.Displayed Column
- ADReferencedTable.Key Column
- ADSelector.Column
- ADTab.Column
- ADTab.Included Column
- ADTab.Order Column
- ADTable.Acctdate_Column_ID
- AD_Audit_Trail.Column
- DataImportElementValue.Column
- DataImportFormatRow.Column
- DataSetColumn.Column