สคีมา
Translation status: ภาษาไทย reader-locale proof. Term names and code fences follow the th-TH pack; supporting prose may still be English.
Declares an application-owned relational heading (experimental).
Aliases: relational heading
Syntax: สคีมา <Name> { คอลัมน์ <type> <name> ... }
Category#
declaration
Related#
Examples#
radix/corpus/schema/schema.fab (canonical · keyword)#
Declares an application-owned relational heading (experimental).
# =============================================================================
# สคีมา — Declares an application-owned relational heading (experimental)
# =============================================================================
#
# What this teaches:
# • Relational headings — `สคีมา Name { ... }` names the columns an application reads from a database result.
# • Declaration only — a สคีมา carries column metadata, not a runtime value, so a program that declares one still runs unchanged.
#
# Common mistakes:
# • Giving a สคีมา methods or `เติมเต็ม` — a สคีมา is a heading, not a ชนิด; both are rejected at parse time.
#
# See also: คอลัมน์, ชนิด
# =============================================================================
# สคีมา — relational heading declaration
#
# GRAMMAR:
# schemaDecl :← 'สคีมา' IDENTIFIER '{' (schemaColumn (NEWLINE schemaColumn)*)? '}'
#
# EXPECTED OUTPUT:
# สคีมา declared
สคีมา Persona {
column string ชื่อ
column int aetas
}
main {
print "schema declared"
}Expected output:
schema declared