Skip to main content
Administrator Guide
Last Updated: 2026-11-13
Prism Domain Specific Language

Prism Domain Specific Language

Prism Domain Specific Language (DSL) is a SQL-like programming language that enables administrators, developers, and Built on Workday (BoW) partners to inspect, write, and manage dataset schemas, tables, and multistage transformation pipelines.
By representing Prism datasets and tables as DSL code, Workday turns complex pipeline logic into machine-readable text
.
This enables AI agents and LLMs to analyze and troubleshoot pipelines automatically while enabling Built on Workday (BoW) partners to view and edit Prism artifacts as source code.
This topic details syntax conventions, lexical rules, statement structures, and validation rules for creating and managing Prism datasets and tables.
Notations
The syntax definitions in the language use these notations:
Notation
Meaning
KEYWORD
Literal keyword (case-insensitive)
<name>
Placeholder
[ ... ]
Optional
{ a | b }
Choose exactly 1
...
Previous element may repeat (comma-separated unless stated otherwise)
Lexical Rules
These parser rules describe how the parser interprets keywords, identifiers, literals, and other tokens:
Element
Rules
Example
Keywords
Case-insensitive
IMPORT, import, Import
Identifier
Letter or _, then letters, digits, _
employee_id, _tmp1
Quoted identifier
Backticks or square brackets; needed for spaces, special characters, or reserved words
`first name`, [cost center]
String literal
Single or double quotes
'Active', "Worker"
Integer
Optional leading
100
Boolean
TRUE / FALSE
Comments
/* ... */ block comments. -- line comments depending on parser configuration
Whitespace
Insignificant; statements can span any number of lines
Additional Parsing Rules
  • You can use most keywords, such as DATASET, FILTER, NAME, CODE, MESSAGE as bare field or table names.
    Exceptions
    :
    Words requiring quotes when used as identifiers include ANTI, MODIFY, and reserved SQL words not present in the standard SQL keyword-identifier list. Example: AND, OR, NOT, NULL, TRUE, FALSE.
  • Do not include a trailing semicolon (;) when terminating a statement. You can submit empty input without executing an operation.
Top - Level Statements
DSL supports these top-level statements:
  • CREATE DATASET ... AS PIPELINE (...) defines a derived dataset as a pipeline of transformation stages.
  • CREATE TABLE ... (...) defines the schema of a Prism table.
Create Dataset
The CREATE DATASET statement defines a derived dataset as a pipeline of transformation stages.
Syntax
CREATE [OR REPLACE] DATASET [IF NOT EXISTS] <dataset_name> AS PIPELINE ( [ WITH <pipeline_id> AS PIPELINE ( <stage> ... ) [, <pipeline_id> AS PIPELINE ( <stage> ... ) ...] ] <stage> ... ) [DISPLAY NAME '<text>'] [COMMENT '<text>']
Pipeline Structure and Rules
  • Primary pipeline: Define the stages directly inside the outer PIPELINE (...). Include at least 1 stage.
  • Secondary pipelines (WITH clause): List comma-separated, unique subpipeline names that the primary pipeline consumes using JOIN or UNION ALL.
  • Stage separation: Separate stages in any pipeline using whitespace only. Don’t use commas.
  • Initial stage requirement: Begin every primary or secondary pipeline with an IMPORT stage.
  • Dataset options (DISPLAY_NAME, COMMENT): Include dataset options in any order, ensuring each option appears at least once.
Example
CREATE OR REPLACE DATASET Employee_Comp AS PIPELINE ( WITH salary_pipeline AS PIPELINE ( IMPORT Salary FILTER base_salary > 0 ) IMPORT Employee INNER JOIN salary_pipeline ON Employee.employee_id = salary_pipeline.employee_id OUTPUT FIELDS Employee.*, salary_pipeline.base_salary ) DISPLAY NAME 'Employee Compensation' COMMENT 'Employees joined with base salary'
Create Table
The CREATE TABLE statement defines the schema and attributes of a Prism table.
Syntax
CREATE [OR REPLACE] TABLE [IF NOT EXISTS] <table_name> ( <column_name> <data_type> [<column_attribute> ...] [, ...] ) [DISPLAY NAME '<text>'] [COMMENT '<text>'] [ENABLE FOR ANALYSIS { TRUE | FALSE }]
Define column attributes immediately following the data type. You can list attributes in any order, separating them with whitespace. This table details each supported attribute, its syntax, and its usage constraints:
Attribute
Type
Comments
NOT NULL
Constraint
Required field
DEFAULT '<value>'
Constraint
Enter the value as quoted text. Example: "value".
EXTERNAL ID
Constraint
Identifies the column as an external ID for matching outside records.
DISPLAY NAME '<text>'
Property
PARSE FORMAT '<pattern>'
Property
Specify a pattern to read dates and times. Example: 'YYYY-MM-DD'.
COMMENT '<text>'
Property
Column description
Rules
  • Column Constraints (NOT NULL, DEFAULT, EXTERNAL ID): Include each constraint only once per column.
  • Table Options: Include each option only once per table.
  • Analysis Setting (ENABLE FOR ANALYSIS): Provide an explicit boolean value (TRUE or FALSE). Workday produces an error when you omit it.
Example
CREATE TABLE Worker_Load ( worker_id STRING NOT NULL EXTERNAL ID DISPLAY NAME 'Worker ID', hire_date DATETIME PARSE FORMAT 'yyyy-MM-dd' DISPLAY NAME 'Hire Date', salary DECIMAL(18, 2) COMMENT 'Annual salary', status STRING DEFAULT 'Active', worker INSTANCE("068c210fed5f44a9916cf97dbd33893f") ) DISPLAY NAME 'Worker Load'