The references are used in the Column tab of the Table and Column window to control what and how is displayed in a certain field. The references can have one of the three validation types: Data Type, List Validation or Table Validation. The selected type is usually based on how the field is used and on the desired control level. The Data Type - Validation Type is used to define the different field types (button, date, number). Usually, it is not necessary to create new references for this validation type, as these are found by default in the System.
The standard data type supported by SocrateCloud are:
Account : use for the fields that register the accounting combinations;
Amount : numerical field with four decimals, used to represent the sums;
Assignment : used to assign the resources;
Binary : used to store the binary data;
Button : used to display a field as a button;
Costs+Prices : used to display the numerical fields;
Date : used to display date fields without date and hour;
Date+Time : used to display date fields with date and hour;
FileName : used to display the name of a local file;
ID : the main key for each table. For each record, SocrateCloud generates a unique ID for the column, using an internal sequence;
Image : used to allow the users to add images to the window;
Integer : used to display integer numbers;
List : used to allow the users to select a value from a list;
Location (Address) : used for address-related fields. For these fields, the users can access a pop-up window where they will enter the address.
Locator (WH) : used to indicate a list with locations close to a warehouse;
Memo : used for fields where you can enter texts bigger than 2000 characters;
Number : used for any numerical field;
Printer Name : used to select a printer;
Product Attribute : used to bring a dynamic pop-up window generated based on an attribute associated to a product;
Quantity : used for the quantity fields;
Search : used to bring a pop-up window where users can enter various search criteria;
String : used for fields with numerical strings;
Table : used for external sending keys to other entities in the system. A dialogue box containing the identifier of the columns in the table referred to will be displayed;
Table Direct : similar to Table, without mentioning the reference table;
Text : used for character strings of up to 2000 characters;
Text Long : used for character strings longer than 2000 characters;
Time : used to represent the date and hour;
URL : used to represent the URLs;
Yes-No : used to represent the fields with selection lists that contain the values Yes, No or and If the column is mandatory, this field will be displayed as a checkbox.
The Table Validation - Validation Type is used when you wish to present to the user a list of selection values and this is based on a table where the users can or cannot add records. When selecting this validation type, the Table Validation tab is activated. Here you can select the Table and the Key Column for the selected table. In the Display Column field you can select what will be displayed in the selection lists.The Display Value checkbox should only be selected if you want the value of the field to be displayed in the selection list.
By selecting the Display Identifiers checkbox, the selection list will display all the fields that have been indicated as identifiers for the table.
You can enter SQL WHERE and SQL ORDER BY clauses to control what will be displayed in the lists and the order they will be displayed in.
The List Validation - Validation Type is used when you wish to present the user with a selection list that has been defined in the Reference window. These lists are more often used in situations where there is a logic of association to the selected values, therefore a code is involved. In these situations, the possible values must be known. When selecting this validation type, the List Validation tab is activated. This is where you will enter the values that will be available for selection. The Search Key field is used to control the sequence in a list, whereas the Name field is the one that is presented to the user for selection.