Table and Column

This is closely related to database, it is kind of metadata of the database tables and columns translated to Adempiere “object” notation.

Tables

  • Case sensitive
  • If the table has an ID it must be exact case with the table name (i.e. CUST_MyTable – the column id must be named exactly CUST_MyTable_ID)
  • View – to define the table definition as view, views are not synchronized in database
You can use it also to make a table read-only
  • Data Access Level – Used for defining the default access for roles
  • Maintain Change Log – when selected all changes to this table are logged in AD_ChangeLog table – it doesn't matter if the role is logged or not
  • Window – define the window to enable zoom functionality. Also you can define a different zoom window for purchase process (PO Window).
  • Records deleteable – to allow/disable deletion of records in database
  • High Volume - indicates if a search screen will display as opposed to a pick list for selecting records from this table.
  • Create Columns from DB: If you make changes in database (ALTER TABLE ADD/MODIFY columns) – you can get the changes with this process.
  • Copy Columns From Table: This is the quickest process to create a table – you select a similar table and this process will create all columns with exact columns (the ID will be renamed to match the table name) – then you can edit (add/delete/change) the columns and when you finish just push the button Synchronize Column to create the table in database.

Columns

  • System Element – the DB Column Name, Name, Description and translation will be inherited from the element at saving time.
  • DB Column Name – the exact name of the column in the database
  • Column SQL – for virtual columns. Virtual columns can show summary information, or information from other tables without the need of adding a real column to the database. Is constructed with a select joined with the main table.
  • Reference: Data Type of the column- each reference correspond to a different behavior in GUI. Please note carefully the difference between Table and Table Direct. Table Direct needs exact match of the case for the table with the name of the column (excepting the suffix _ID)
  • Please note also the difference between Table and Search
  • For buttons you can define an associated process
  • For Amount, Date, Integer, Number, Quantity you can define a range of min and max value
  • Validation: Dynamic change for list and searches
  • Reference Key: Static list for tables and lists
  • Value Format: For strings you can define a format for the field. Adempiere formatting can enforce the usage of space, any letter, uppercase, lowercase, letters & digits, only digits, etc. I.e. Formatting phone numbers
  • Default Logic: Context variables – SQL Statements. You can define several defaults separated by “;” - the first one not-null will be the default
  • Key Column: Just one per table (Primary Key – normally ID generated internally, not shown for users)
  • Parent Link Column – Define the child relation with one or more tables – there can be tables without ID but with one or more parents (like Access tables)
  • Mandatory
  • Updateable
  • Always updateable – make this field always updateable, even if is processed
  • Encryption: just for strings – no reversal process – you can loose data, you need to ensure the width of the column can hold all the current values.
  • Read only logic – condition for making the record read-only (by default IsActive and Processed columns mark the record as readonly without the need of defining the logic here)
  • Mandatory logic – condition for making this field mandatory
  • Identifier: one or more columns (normally value and/or name) to be shown in lists and for dereferencing in reports. The identifiers are shown in the order defined in the field Sequence
  • Callout – piece of code (customization) for filling other fields or simple validations (not recommended for validations – you still need to validate on saving) – for string fields callout is called in keystroke basis
  • Selection column – define the column(s) to be shown in the default search window – by default Value and Name columns are searchable
  • Translated – to define translations for a column – in this case you need to define a table and a tab with the same name as the original table and the suffix (_Trl), and create the table with the same key as the parent, language column and the translated columns

Comments

Popular posts from this blog

Print Paper

ADempiere can do.