uc-apx create region interactive-report
Insert a new interactiveReport region backed by an inline SQL query.
The CLI only scaffolds the sqlQuery shape (source { location: localDatabase, type: sqlQuery, sqlQuery: ``` ... ``` }).
Author the SELECT yourself — including any WHERE / ORDER BY / joins.
--column drives the report’s column children with the UPPERCASE source.dataType
values APEX uses for interactive reports (STRING, NUMBER, DATE, CLOB).
uc-apx create region interactive-report [flags]| Flag | Type | Default | Description |
|---|---|---|---|
--column | string | Comma-separated columns. Syntax: NAME[:TYPE[:LENGTH]]. TYPE ∈ varchar2 (default), number, date, timestamp, clob. At least one column is required [required] | |
--column-span | int | 12-col grid span for the region’s layout (0 = omit; e.g. 6 for a half-width region) | |
--dry-run | Print rendered region to stdout without writing | ||
--force | Reserved for future use | ||
--id | string | Region id (default: kebab-case of —name) | |
--name | string | Display name of the region [required] | |
--page | string | Target page (numeric ID, alias, or name) [required] | |
--sequence | int | Layout sequence (default: max existing + 10) | |
--slot | string | body | Page slot to place the region in |
--sql | string | Inline SQL query (or @path/to/file.sql to read from disk; @@ escapes a literal leading @) [required] |
Global Flags
Section titled “Global Flags”| Flag | Type | Default | Description |
|---|---|---|---|
--app-dir | string | . | Path to the APEX application directory |
--json-pretty | Output in pretty-printed JSON (human-readable) instead of minified JSON | ||
--toon | Output in TOON format (human-readable, token-efficient) instead of JSON |
Example Generated APEXlang
Section titled “Example Generated APEXlang”Using --dry-run to preview the generated construct (no files are written):
uc-apx --app-dir examples/brookstrut create region interactive-report --page 46 --name Product Report --sql select product_id, product_name, unit_price from oow_demo_products --column PRODUCT_ID:number,PRODUCT_NAME:varchar2:100,UNIT_PRICE:number --dry-runGenerated APEXlang
region product-report ( name: Product Report type: interactiveReport source { location: localDatabase type: sqlQuery sqlQuery: ```sql select product_id, product_name, unit_price from oow_demo_products ``` } layout { sequence: 50 slot: body } appearance { template: @/interactive-report templateOptions: #DEFAULT# } pagination { type: rowRangesXToY } messages { whenNoDataFound: No data found. }
column PRODUCT_ID ( type: plainText heading { heading: Product Id alignment: end } layout { sequence: 10 columnAlignment: end } source { dataType: NUMBER } )
column PRODUCT_NAME ( type: plainText heading { heading: Product Name } layout { sequence: 20 } source { dataType: STRING } )
column UNIT_PRICE ( type: plainText heading { heading: Unit Price alignment: end } layout { sequence: 30 columnAlignment: end } source { dataType: NUMBER } ) )