Skip to content

Table2

An exemplar schema demonstrating foreign key relationships and additional constraints

Primary Key

id

Foreign Keys

Fields Reference Resource Reference Fields
table1Id table1 id

Fields

Name Definition Type
id

Unique identifier for the record

Constraints
  • required: true
  • pattern: ^t2-[0-9]{3}$
Examples
  • t2-001
  • t2-002
  • t2-003
string
table1Id?

Reference to the parent table1 record. If not provided, the record is independent

Examples
  • t1-001
  • t1-002
string
title

Title or name of the item

Constraints
  • required: true
  • minLength: 1
  • maxLength: 200
Examples
  • First Item
  • Second Item
  • Sample Entry
string
amount

Monetary or numeric amount

Constraints
  • required: true
  • minimum: 0
Examples
  • 99.99
  • 150.5
  • 2500
number
priority

Priority level of the item

Constraints
  • required: true
  • enum: low, medium, high
Categories
  • low
  • medium
  • high
Examples
  • low
  • medium
  • high
string
percentage?

Percentage value between 0 and 100

Constraints
  • minimum: 0
  • maximum: 100
Examples
  • 25.5
  • 50
  • 75.25
  • 100
number
notes?

Additional notes or comments

Constraints
  • maxLength: 500
Examples
  • This is a note
  • Additional information here
string
isActive

Whether the item is currently active

Constraints
  • required: true
Examples
  • true
  • false
boolean