Agent skill

Mendix Odata Pushdown

by mendixlabs in mendixlabs/mxcli

Push OData query options into the SQL of a Mendix resource served by a read microflow, so $filter, $orderby, $top, $skip, $count and the key lookup reach the database instead of being silently…

Apache-2.0Auto-check passedDatabases

Install Mendix Odata Pushdown

skills CLI
$ npx skills add mendixlabs/mxcli --skill mendix-odata-pushdown -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install mendixlabs/mxcli mendix-odata-pushdown --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/mendixlabs/mxcli.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/packs/mendix-odata-pushdown .claude/skills/mendix-odata-pushdown && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
mendix-odata-pushdown
GitHub stars
128
Token cost
~2.5k tokens
SKILL.md length
1,259 words
Files
14 (incl. scripts, references)
Skills in repo
72
Repo updated
First seen
Licence
Apache-2.0

At a glance

Push OData query options into the SQL of a Mendix resource served by a read microflow, so $filter, $orderby, $top, $skip, $count and the key lookup reach the database instead of being silently…

  • Publishing an OData resource over data Mendix has no table for — a warehouse view
  • SKILL.md covers The problem this exists for, What the pack gives you, Two ways to spend it and Columns — the whitelist, and…, plus 5 more sections
  • Runs Java scripts from its folder; calls javac and java
  • A legacy database

What it does

Mendix Odata Pushdown is an agent skill from mendixlabs/mxcli. Push OData query options into the SQL of a Mendix resource served by a read microflow, so $filter, $orderby, $top, $skip, $count and the key lookup reach the database instead of being silently dropped. Use when publishing an OData resource over data Mendix has no table for — a warehouse view, a legacy database, a Databricks catalogue, a stored procedure, a CSV read through a connector — or when a published resource returns 200 with the wrong rows and nothing appears in the log.

Its SKILL.md is about 2.5k tokens, which your agent loads only when the skill is triggered. The skill folder holds 18 other files, including scripts and reference files (for example `pack.yaml`, `references/failure-modes.md` and `references/packaging-gap.md`).

It sits in Databases, covering SQL and CSV and tabular files. It works with SQL and Databricks. The repository describes itself as: Mendix cli tool, a headless way to work with Mendix projects. Enables Mendix projects for use with 3rd party agentic coding tools like Claude Code and Copilot. Includes a… The licence is Apache-2.0.

When your agent uses it

  • Publishing an OData resource over data Mendix has no table for — a warehouse view
  • A legacy database
  • A Databricks catalogue
  • A stored procedure

Example prompts

  • “/mendix-odata-pushdown”

What it can do on your machine

Read from SKILL.md and the folder at commit 20a6c89. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 1 file in scripts/ (Java), which the agent can run.

    Shell commands in SKILL.md call:

    • javac
    • java

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Mendix Odata Pushdown loads about 2.5k tokens when it runs, and up to ~6.4k if it reads all its reference files. Until then it costs about 126 tokens; SKILL.md has 1,259 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~126
When it runs · the whole SKILL.md, loaded when a task matches
~2.5k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~6.4k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from mendixlabs/mxcli at commit 20a6c89, republished under its Apache-2.0 licence (© mendixlabs). 1,259 words, ~2,467 tokens.

Download SKILL.mdSave it as .claude/skills/mendix-odata-pushdown/SKILL.md (or your agent's skills folder). This skill also uses 13 other files; get the full folder from GitHub.
name
mendix-odata-pushdown
description
Push OData query options into the SQL of a Mendix resource served by a read microflow, so $filter, $orderby, $top, $skip, $count and the key lookup reach the database instead of being silently dropped. Use when publishing an OData resource over data Mendix has no table for — a warehouse view, a legacy database, a Databricks catalogue, a stored procedure, a CSV read through a connector — or when a published resource returns 200 with the wrong rows and nothing appears in the log.

Pushing OData query options into your own SQL

The problem this exists for

Mendix will publish any entity over OData, including one with no table behind it: declare the resource non-persistable, give it a read microflow, done. What the documentation does not say is that Mendix then applies none of the query options to your answer. $filter, $orderby, $top, $skip, $count and the key lookup all arrive on the request URI and all stay there. Whatever the microflow returns is exactly what the client gets.

That is not a 500 and not an empty grid. It is a 200 with the wrong rows:

  • ?$top=5 returns all 917 rows and the widget shows five of them, so paging looks correct while every page ships the whole table.
  • A client re-reading one held row by key gets the collection back, adopts the first row as that object's identity, and keeps it. A detail page for one record shows another record's data, and nothing logs a word.

The second one is the reason to care. It is not a performance problem; it is wrong data on screen, and every check is green.

What the pack gives you

Four Java actions and the entity they return. Nothing in them is specific to any database or any app.

{{MODULE}}.Parse(Uri, Columns, Dialect, MaxTop, DefaultTop,
                 DefaultOrderBy, KeyField, RejectUnsupported) -> {{MODULE}}.Query
{{MODULE}}.Key(Uri, KeyField)                                 -> String
{{MODULE}}.FilterNumber(Uri, Field, Fallback)                 -> Long
{{MODULE}}.CallStatement(Routine, Kind, Parameters, Dialect)  -> String

Parse is the whole thing. Key and FilterNumber are short forms for the common case — a resource reachable one way only ("the sessions of this weekend"), whose entire contract is one value out of $filter. CallStatement builds the invocation for a resource backed by a stored routine.

{{MODULE}}.Query
FieldStyleWhat it is
FilterSqlsplice" WHERE …", or empty
OrderBySqlsplice" ORDER BY … LIMIT n OFFSET m"
SelectSqlsplice" a, b, c" for $select, or empty for all columns
SelectedColumnsbindthe same columns as exposed names
Keybindthe key the client is re-reading one row by; empty for a collection
Top, Skipbindthe page, already clamped to MaxTop
SortColumn1/2, SortDirection1/2bindthe sort, as exposed names and A/D
WantsCountboth$count=true — the client wants the size of the set
Rejected, RejectReasonbindthe request asked for something untranslatable. Only a bind caller sees these: with RejectUnsupported = true (what a splice caller passes) Parse throws instead of returning, so a splice caller always has Rejected = false

Two ways to spend it

Which one you get is decided by whether you own the SQL.

Splice — you build the statement, so concatenate the fragments into it.

$Q = CALL JAVA ACTION {{MODULE}}.Parse(
  Uri = $Request/Uri, Columns = $Cols, Dialect = 'postgresql',
  MaxTop = 500, DefaultTop = 500, DefaultOrderBy = 'name ASC',
  KeyField = 'driverId', RejectUnsupported = true);

DECLARE $Sql String = $Select + $Q/FilterSql + $Q/OrderBySql;

Bind — the SQL lives somewhere you cannot rewrite: a named query on a database connection, a view, a procedure. Take the values, pass them as parameters. This style is why the module is not simply a SQL builder: most data worth publishing this way sits behind SQL somebody else owns.

references/patterns.md has the working shape of both, including the CASE construction that makes a fixed statement sortable by a parameter.

Columns — the whitelist, and why the type is not decoration

exposedName:sqlExpression:type, comma-separated:

'name:d.name:text,wins:d.race_wins:number,active:d.is_active:bool,born:d.dob:date'

Nothing outside this list can be filtered or sorted on, and a filter naming something outside it is a rejection, not an omission.

Mendix quotes a literal according to what the widget believes the attribute is, which is not always what the column is: a combo box on a numeric key sends year eq '1957' while the grid header above it sends year eq 1957. Passing the quotes through gives the engine year = '1957' against a BIGINT — zero rows, status 200. The type is what makes both spellings mean the same thing.

What it understands

Everything Mendix's OData client emits, and nothing else.

comparisonseq ne gt ge lt le
functionscontains startswith endswith
logicand or not, parentheses, correct precedence
literalstext, numbers, decimals, true/false, null, ISO instants
options$filter $orderby (two terms) $top $skip $count
the key?$filter=k eq 'v', /Res('v'), /Res(k='v')
dialectspostgresql duckdb sqlserver oracle mysql

OData itself is far larger — arithmetic, lambdas, $apply, date functions, any/all. None of it is emitted by a Mendix client, so none of it is here. A request outside the grammar is rejected, not ignored: Rejected comes back true and the caller is expected to fail the request. Dropping a filter you could not read returns more rows than were asked for and calls it success, which is the bug the module exists to stop.

Show full SKILL.md (544 more words)Show less

Install

bash
mxcli skill add mendix-odata-pushdown --apply -p App.mpr

Then add {{MODULE}}.User to whichever user roles your published service runs as — the pack cannot do that itself without knowing your role names.

--apply writes to the model: a module, the Query entity, a module role and four Java actions. Without it the pack only copies its own files.

Not installable yet. installs.java is a proposed manifest target that mxcli does not implement, and without it the MDL applies but the helper classes it delegates to never reach javasource/. references/packaging-gap.md has the detail and the manual fallback.

FileFor
references/patterns.mdsplice and bind end to end, and the sortable-fixed-statement CASE
references/failure-modes.mdwhat breaks, symptom first
references/packaging-gap.mdwhy this pack does not install, and how to apply it by hand

$select narrows the read, it does not fix the answer

SelectSql is the one option here that is an optimisation rather than a correction, and it is worth knowing which before spending time on it.

Mendix applies $select to the response itself — measured on 11.13, on a microflow-backed resource as much as on a database read — so the client already receives only the fields it asked for whatever the microflow does. What pushing it down saves is reading columns nobody will look at: real time over a wide CSV through a columnar reader, nothing at all over a narrow table.

The consumer drives it. An external entity with attributes removed sends a narrower $select, because it has nowhere to put what it dropped — so the projection is negotiated end to end without either side arranging it.

Splice it after SELECT, and keep your own list when it is empty:

sql
SELECT {{SelectSql or your full list}} FROM read_csv_auto(?) AS t
{{FilterSql}}{{OrderBySql}}

Three behaviours worth relying on:

  • The key is always projected, even when $select omits it. It costs one column and stops a caller that dedupes, associates or re-reads by key from losing the value it does that with. The client still sees only what it asked for, because Mendix projects the response.
  • An unknown column is rejected, not skipped. A wrong sort order is cosmetic and is ignored; a dropped projection is not — answering with a null where data was expected is the same "200 and wrong" this component exists to prevent.
  • Sort columns are not forced into the projection. ORDER BY may name a column the SELECT list omits; that is ordinary SQL, and adding them would defeat the narrowing.
What is still not translated

$expand is not supported, and is rejected rather than ignored when RejectUnsupported is on. It is a different kind of work from everything else here: not a projection but a join producing a nested object graph, which the microflow would have to build as associated Mendix objects, with nested options ($expand=X($filter=…;$top=3)) multiplying the surface. $search, $apply and the lambda operators (any/all) are unhandled for the same reason — each is a new grammar rather than a new clause.

Checking it without an app

bash
mkdir -p /tmp/pc/odatapushdown
sed -e 's/{{MODULE_PATH}}/odatapushdown/g' -e 's/{{MODULE}}/ODataPushdown/g' \
    java/ODataQueryParser.java > /tmp/pc/odatapushdown/ODataQueryParser.java
javac -d /tmp/pc /tmp/pc/odatapushdown/ODataQueryParser.java scripts/ParserCheck.java
java -cp /tmp/pc ParserCheck

ParserCheck exits non-zero on the first failure and prints what it expected. It covers the projection, the filter grammar's quoting of numeric columns, the sort terms, the MaxTop clamp, $count, and that an unreadable filter is rejected rather than dropped. A dialect regression here is invisible to mx check and to every test that needs an app, which is why it is worth a second.

© mendixlabs, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 13 other files (scripts, references) in .claude/skills/packs/mendix-odata-pushdown of mendixlabs/mxcli.

  • SKILL.md
  • java/ODataQueryParser.java
  • java/QueryObject.java
  • java/RoutineCall.java
  • java/actions/CallStatement.java
  • java/actions/FilterNumber.java
  • java/actions/Key.java
  • java/actions/Parse.java
  • mdl/module.mdl
  • pack.yaml
  • references/failure-modes.md
  • references/packaging-gap.md
  • references/patterns.md
  • scripts/ParserCheck.java

Open the folder on GitHubat commit 20a6c89

Compare with similar skills

Mendix Odata Pushdown next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Mendix Odata Pushdown compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Mendix Odata Pushdown this skillmendixlabs/mxcli128—~2.5kAutomated safety check: PassApache-2.0
Dummy Datasetkillvxk/pm-skills-zh168—~595Automated safety check: PassMIT
Jeecg Onlformjeecgboot/skills239—~7.7kAutomated safety check: PassApache-2.0
Duckdb EnaAAaqwq/AGI-Super-Team1051 repos~1.6kAutomated safety check: PassMIT
Chdb SQLvemetric/vemetric3941 repos~1.2kAutomated safety check: PassApache-2.0
Rust SQL Testshencangsheng/easydb_app590—~1.2kAutomated safety check: PassMIT

Similar skills

  • Dummy Dataset

    killvxk/pm-skills-zh

    生成用于测试的逼真虚拟数据集,支持自定义列、约束条件及输出格式(CSV、JSON、SQL、Python 脚本)。适用于创建测试数据、构建模拟数据集,或为开发和演示生成示例数据。

    168 GitHub stars~595 tokensUpdated 6 mo ago
    DatabasesAuto-check passed
  • Jeecg Onlform

    jeecgboot/skills

    JeecgBoot Online表单(cgform)全生命周期管理——通过API自动创建/编辑数据库表和表单配置, 支持单表、主子表、树表,26种控件类型,以及JS/Java/SQL增强、权限配置、数据CRUD、积木报表集成。

    239 GitHub stars~7.7k tokensUpdated 20 days ago
    DatabasesAuto-check passed
  • Duckdb En

    aAAaqwq/AGI-Super-Team

    DuckDB CLI specialist for SQL analysis, data processing and file conversion.

    105 GitHub starsUsed in 1 repo~1.6k tokens
    DatabasesAuto-check passed
  • Chdb SQL

    vemetric/vemetric

    A skill your agent uses when the user wants to run SQL — especially analytical SQL — on local files (parquet/csv/json), URLs, S3 paths, or remote databases (Postgres, MySQL, MongoDB, ClickHouse…

    394 GitHub starsUsed in 1 repo~1.2k tokens
    DatabasesAuto-check passed
  • Rust SQL Test

    shencangsheng/easydb_app

    Enforces unit test requirements for the Rust data-processing modules in src-tauri/src/sql/ (generator.rs, parse.rs) and src-tauri/src/reader/ (excel.rs and other readers).

    590 GitHub stars~1.2k tokensUpdated 1 mo ago
    Documents & OfficeAuto-check passed
  • Databricks Dbsql

    databricks/databricks-agent-skills

    Official

    Databricks SQL (DBSQL) advanced features and SQL warehouse capabilities.

    345 GitHub starsUsed in 1 repo~2.8k tokens
    DatabasesAuto-check passed

More from mendixlabs/mxcli

All 72 skills in this repo
  • Mendix Vega Charts

    mendixlabs/mxcli

    Chart a Mendix app with Vega-Lite through a pluggable widget that takes the specification and the data as separate properties, so the model emits rows and never assembles a chart payload.

    128 GitHub stars~3k tokensUpdated today
    Auto-check passed
  • Agents

    mendixlabs/mxcli

    Author Mendix AI agent documents in MDL — Model, Knowledge Base, Consumed MCP Service and Agent, with variables, tools and multi-line prompts.

    128 GitHub starsUsed in 1 repo~2.2k tokens
    Auto-check passed
  • Mendix Bulk Oql Dml

    mendixlabs/mxcli

    Run set-based INSERT, UPDATE and DELETE against Mendix entities through OQL statements, which the runtime supports and Studio Pro cannot author.

    128 GitHub stars~1.4k tokensUpdated today
    Auto-check passed
  • Business Events

    mendixlabs/mxcli

    Define event-driven APIs over Kafka with Mendix business event services — publish and subscribe contracts, CREATE/DROP/DESCRIBE.

    128 GitHub starsUsed in 1 repo~1.3k tokens
    Auto-check passed
  • Catalog Search

    mendixlabs/mxcli

    Search the Mendix Catalog platform service registry (catalog.mendix.com) from the CLI to find services published across an organisation.

    128 GitHub starsUsed in 1 repo~1.4k tokens
    Auto-check passed
  • Mock REST APIs

    mendixlabs/mxcli

    Stand up an HTTP endpoint you control instead of a live third-party API, and point the Mendix app at it — Prism from an OpenAPI contract, a constant swap, or a forward proxy.

    128 GitHub starsUsed in 1 repo~2.5k tokens
    Auto-check passed

Works with

Questions about Mendix Odata Pushdown

What does Mendix Odata Pushdown do?

Push OData query options into the SQL of a Mendix resource served by a read microflow, so $filter, $orderby, $top, $skip, $count and the key lookup reach the database instead of being silently…. Mendix Odata Pushdown is an agent skill from mendixlabs/mxcli. Push OData query options into the SQL of a Mendix resource served by a read microflow, so $filter, $orderby, $top, $skip, $count and the key lookup reach the database instead of being silently dropped.

When should I use Mendix Odata Pushdown?

Mendix Odata Pushdown fits situations like: publishing an OData resource over data Mendix has no table for — a warehouse view; A legacy database; A Databricks catalogue; A stored procedure.

How do I install Mendix Odata Pushdown in Claude Code?

Run `npx skills add mendixlabs/mxcli --skill mendix-odata-pushdown -a claude-code`. Or copy the skill folder (.claude/skills/packs/mendix-odata-pushdown in mendixlabs/mxcli) into .claude/skills/mendix-odata-pushdown in your project. Claude Code loads it when a task matches its description.

How do I install Mendix Odata Pushdown in Codex?

Run `npx skills add mendixlabs/mxcli --skill mendix-odata-pushdown -a codex`. Or copy the skill folder (.claude/skills/packs/mendix-odata-pushdown in mendixlabs/mxcli) into .agents/skills/mendix-odata-pushdown in your project. Codex loads it when a task matches its description.

Can I use Mendix Odata Pushdown in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add mendixlabs/mxcli --skill mendix-odata-pushdown -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/mendix-odata-pushdown, .gemini/skills/mendix-odata-pushdown, .github/skills/mendix-odata-pushdown and .opencode/skills/mendix-odata-pushdown in your project.

What does Mendix Odata Pushdown need to run?

Going by SKILL.md and its folder, Mendix Odata Pushdown needs Java for the scripts in its folder and the command-line tools its instructions call (javac and java).

Does Mendix Odata Pushdown access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Mendix Odata Pushdown safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Mendix Odata Pushdown use?

Mendix Odata Pushdown is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Mendix Odata Pushdown use?

About 2.5k tokens (SKILL.md is roughly 9.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 3.9k tokens, read only when the agent opens those files.

What are the alternatives to Mendix Odata Pushdown?

Skills that share tags, products or a category with Mendix Odata Pushdown: Dummy Dataset (killvxk/pm-skills-zh, 168 stars), Jeecg Onlform (jeecgboot/skills, 239 stars), Duckdb En (aAAaqwq/AGI-Super-Team, 105 stars) and Chdb SQL (vemetric/vemetric, 394 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Mendix Odata Pushdown?

mendixlabs (a GitHub organization) maintains it in mendixlabs/mxcli, which has 128 GitHub stars. The repository holds 72 skills in this directory. The repository was last updated on October 7, 2026.

Source: mendixlabs/mxcli on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.