While continuing the development of my OllAPEX application, I realized that initializing certain tables containing prompts, descriptions, JSON schemas, was just as important as installing the database objects themselves.
![]() |
| Image courtesy of Google Gemini |
These pieces of information are crucial when talking to the LLMs, they can make a huge difference in the results one gets and can be subject to refinements over time, as I could see first hand when I implemented the "tool calls" functionality in my agentic loops: a sentence, a word can determine if a tool call is made or not.
One nifty feature, albeit not covering 100% of use cases, is APEX's Data Package located in the Supporting Objects section of the Application Builder.
The Data Package functionality allows you to take one or more tables, pack their contents into JSON documents, zip them, allowing an APEX API to read them at installation time, with the option to delete the "package" after a successful import.
Each table content is "packed" into a separate ZIP file containing two JSON files:
one file contains a table layout description while the other contains the actual data, see below for an example:
the "profile"
{ "file-type" : 4, "single-row" : false, "file-encoding" : "AL32UTF8", "row-selector" : "items", "headings-in-first-row" : false, "csv-enclosed" : "\"", "force-trim-whitespace" : true, "columns" : [ { "name" : "ID", "data-type" : 2, "decimal-char" : ".", "data-type-len" : 22, "selector" : "id", "is-json" : false }, { "name" : "FILE_EXT", "data-type" : 1, "data-type-len" : 20, "selector" : "file_ext", "is-json" : false }, { "name" : "MIME_TYPE", "data-type" : 1, "data-type-len" : 120, "selector" : "mime_type", "is-json" : false }, { "name" : "MARKDOWN_LANG", "data-type" : 1, "data-type-len" : 30, "selector" : "markdown_lang", "is-json" : false }, { "name" : "PRIORITY", "data-type" : 2, "decimal-char" : ".", "data-type-len" : 22, "selector" : "priority", "is-json" : false }, { "name" : "IS_ACTIVE", "data-type" : 1, "data-type-len" : 1, "selector" : "is_active", "is-json" : false }, { "name" : "CREATED_AT", "data-type" : 3, "data-type-len" : 7, "selector" : "created_at", "format-mask" : "YYYY-MM-DD\"T\"HH24:MI:SS", "is-json" : false }, { "name" : "IS_TEXT", "data-type" : 1, "data-type-len" : 1, "selector" : "is_text", "is-json" : false }, { "name" : "IS_IMAGE", "data-type" : 1, "data-type-len" : 1, "selector" : "is_image", "is-json" : false }, { "name" : "IS_AUDIO", "data-type" : 1, "data-type-len" : 1, "selector" : "is_audio", "is-json" : false }, { "name" : "IS_VIDEO", "data-type" : 1, "data-type-len" : 1, "selector" : "is_video", "is-json" : false }, { "name" : "IS_ZIP", "data-type" : 1, "data-type-len" : 1, "selector" : "is_zip", "is-json" : false }, { "name" : "IS_CONVERTIBLE", "data-type" : 1, "data-type-len" : 1, "selector" : "is_convertible", "is-json" : false } ], "parsed-rows" : 109 }
"data sample"
{ "items": [ { "id": 3, "file_ext": "gif", "mime_type": "image/gif", "markdown_lang": null, "priority": 1, "is_active": "Y", "created_at": "2026-11-19T10:12:00", "is_text": "N", "is_image": "Y", "is_audio": "N", "is_video": "N", "is_zip": "N", "is_convertible": "N" }, { "id": 4, "file_ext": "pdf", "mime_type": "application/pdf", "markdown_lang": null, "priority": 1, "is_active": "Y", "created_at": "2026-11-19T10:12:00", "is_text": "N", "is_image": "N", "is_audio": "N", "is_video": "N", "is_zip": "N", "is_convertible": "Y" }, { "id": 5, "file_ext": "markdown", "mime_type": "text/markdown", "markdown_lang": "markdown", "priority": 2, "is_active": "Y", "created_at": "2026-11-19T10:12:00", "is_text": "Y", "is_image": "N", "is_audio": "N", "is_video": "N", "is_zip": "N", "is_convertible": "N" }, { "id": 6, "file_ext": "html", "mime_type": "text/html", "markdown_lang": "html", "priority": 1, "is_active": "Y", "created_at": "2026-11-19T10:12:00", "is_text": "Y", "is_image": "N", "is_audio": "N", "is_video": "N", "is_zip": "N", "is_convertible": "N" }, { "id": 7, "file_ext": "jpg", "mime_type": "image/jpeg", "markdown_lang": null, "priority": 1, "is_active": "Y", "created_at": "2026-11-19T10:12:00", "is_text": "N", "is_image": "Y", "is_audio": "N", "is_video": "N", "is_zip": "N", "is_convertible": "N" }, { "id": 8, "file_ext": "htm", "mime_type": "text/html", "markdown_lang": "html", "priority": 2, "is_active": "Y", "created_at": "2026-11-19T10:12:00", "is_text": "Y", "is_image": "N", "is_audio": "N", "is_video": "N", "is_zip": "N", "is_convertible": "N" }, { "id": 9, "file_ext": "csv", "mime_type": "text/csv", "markdown_lang": "csv", "priority": 1, "is_active": "Y", "created_at": "2026-11-19T10:12:00", "is_text": "Y", "is_image": "N", "is_audio": "N", "is_video": "N", "is_zip": "N", "is_convertible": "N" } ] }
While the script is saved in the "Installation Scripts" section of the Supporting Objects, the ZIP files are stored in the Shared Components / Static Application Files.
The following is the corresponding installation script:
begin
--FILE_EXTENSIONS: 109/10000 rows exported, APEX$DATA$PKG/FILE_EXTENSIONS$191000
apex_data_install.load_supporting_object_data(p_table_name => 'FILE_EXTENSIONS', p_delete_after_install => true );
end;In case of multiple tables the script will contain multiple calls to the API.
As long as the tables are made up of simple SQL objects (VARCHAR2, NUMBER, DATES, ...) all works just fine, from the comment included in the script I guess there is a limit of 10000 rows, considering this functionality is meant for moving "static" data I think it's a fair limitation.
The problems may arise if there are tables containing CLOBs longer than 1000 characters or BLOBs.
BLOBs are a show-stopper, the Data Package wizard will return a warning if you try to export a table containing a BLOB column.
CLOBs are successfully imported if they are 1000 characters or less, otherwise they will be truncated.
If you look at the JSON profile file, it will define the column as type 11, 4000 bytes, which explains why they are truncating to 1000 characters in an AL32UTF8 character set (up to 4 bytes per character in AL32UTF8), just to stay safe.
This is why today I submitted an APEX Idea suggesting to handle properly also CLOB and BLOB columns, the latter data type could be base64-encoded to make it easier to deal with in the JSON format.
Aside from a short release video back in APEX 21.2, official documentation on Data Packages is virtually zero, so most of these limits only show up once you test them in the wild. Give the APEX Idea a vote if you'd like to see full CLOB and BLOB support added—and hope you found this helpful!


