Manual Tables & Fields

Field types — pick the right one

The type decides what input shows on the form and how the value is stored. Pick the most specific type — it gives users a friendlier form.

Most common

Type Use it for Form looks like
Text Short labels, names, IC numbers (under ~250 chars) Single-line text box
Long text Reasons, descriptions, notes Multi-line text area
Number Quantities, counts, ages Number-only input
Date Start dates, due dates, dates of birth Date picker
Date & time Submitted at, meeting starts Date & time picker
Yes / No Flags like Active, Completed Toggle switch
Email Email addresses Text box that validates name@host
Phone Mobile / office numbers Text box that allows +, -, spaces
Dropdown A short list of choices (statuses, categories) Dropdown / select

Less common but useful

Type Use it for
File A document upload (PDF, DOCX, image)
Image A photo (with thumbnail preview)
Money Amounts in RM — formatted with thousands separator
Decimal Values that need precision (weights, ratings)
Link to another table Connect this record to a record in another table (e.g. Leave application → Staff)

How to pick

Ask yourself: what is the user typing? Match the type to that:

  • A choice from a fixed list → Dropdown.
  • A free-form sentence or paragraph → Long text.
  • A whole number → Number.
  • An amount of money → Money, not Number — the formatting matters.
  • A flag → Yes / No, not a Dropdown of "Yes"/"No".

Why type matters

The type controls:

  • Input — date pickers vs number spinners vs file uploads.
  • ValidationEmail rejects not-an-email; Number rejects letters.
  • DisplayMoney shows RM 1,234.56; Date shows 15 Jun 2025; Yes / No shows a coloured badge.
  • FilteringDate gets a date range filter on the list page, Dropdown gets a multi-select.

Get the type right and you get all of this for free.

Where to next

  • Required, unique, indexed — constraints on top of the type.
  • Defaults & validation — pre-fill values, custom rules.