Chapter 1: Understanding Application Language (AL)
Objectives
By the end of this chapter you will be able to:
- Explain what AL is and where it runs in Business Central
- Describe why extensions replaced direct base-application edits
- Identify the main AL object types and what each one is responsible for
- Trace how this book’s loan-repayment example will evolve across later chapters
1.1 What is AL?
Application Language (AL) is Microsoft’s language for building and extending Dynamics 365 Business Central. It is designed for ERP workflows, data validation, and process automation inside Business Central, and it isn’t a general-purpose desktop language.
With AL you define:
- Data structures (tables)
- User experiences (pages)
- Business rules (codeunits and triggers)
- Output and integration surfaces (reports, APIs, events)
1.2 From C/AL to AL: Why the model changed
Earlier Dynamics products used C/AL, and you customized them by editing the base objects directly. AL introduced an extension-first model, so your custom logic is packaged separately from Microsoft’s base app.
Extensions isolate your changes from core product code and reduce upgrade risk. They also support clean deployment and versioning, and they let multiple partners work on one tenant more safely.
Chapter 11 comes back to this with app.json, package metadata, and permission sets.
1.3 AL object types and responsibilities
A common beginner mistake is to put all the logic in one object. In this book, each object has a clear job:
- Table: schema and integrity rules
- Page: data entry and user actions
- Codeunit: reusable business procedures
- Permission set: who can do what
- Test codeunit: automated verification
The case study in Chapter 16 depends on this separation.
1.4 The running example for this book
From Chapter 7 to Chapter 16 you’ll build a Loan Repayment Management extension. The steps come in a deliberate order:
- Create table structure and constraints (Chapter 7)
- Add a list page and actions (Chapter 8)
- Move logic into codeunits (Chapter 9)
- Package and secure the extension (Chapters 11 and 15)
- Protect behavior with tests (Chapter 14)
You won’t write any code in this chapter. The aim is to understand why that architecture is the right one.
Chapter summary
- AL is Business Central’s extension language for ERP data and workflows
- Extension packaging replaced direct base-code customization for upgrade safety
- Object responsibilities must be kept separate (table/page/codeunit/security/tests)
- Later chapters build one coherent loan-repayment extension from end to end
Tasks
- Architecture mapping. Write one sentence each for what belongs in a table, page, and codeunit.
- Upgrade reasoning. Explain why extension packaging is safer than editing base objects directly.
- Continuity checkpoint. List the first three chapters where the Loan Repayment example is implemented (by chapter number and purpose).
Check your work: your answers should align with the object separation used in Chapters 7–9 and the end-to-end flow in Chapter 16.