Skip to content

Releases

v2026.11.05 — Display attributes in BICS results

Choose a tag to compare

@jrosskopf jrosskopf released this 05 Nov 18:32
2db57e7

Added

  • [bics] Display attributes of a characteristic come back from sap_bics_result as their own VARCHAR
    columns named <char>__<attr>, e.g. 0D_NW_PROD__0D_NW_PRDGP, placed after the _HIER_LEVEL columns.
    Attributes the query definition activates appear without any extra call, as in RSRT; previously they were
    listed by sap_bics_describe but never returned. (#179)
  • [bics] sap_bics_attributes(state, char, attr, ..., op => 'ADD'|'SET'|'REMOVE') switches display
    attributes on or off in a session, for cubes and queries alike. (#179)

Fixed

  • [bics] With a display attribute active, the characteristic's own column no longer picks up attribute
    values: in DISPLAY = 'TEXT' it showed the last attribute value instead of the member text, and in
    'BOTH' every attribute value was appended to key and text. (#179)

v2026.10.28 — BEx variables on BW 7.50

Choose a tag to compare

@jrosskopf jrosskopf released this 28 Oct 05:05
4897a0c

Fixed

  • [bics] sap_bics_describe(cube, query) and sap_bics_variables work on classic BW 7.x again for queries
    with variables. BW 7.50's BICS does not report IS_EXIT_VARIABLE, and the variable mapping added in
    v2026.10.01 failed the whole call with Field 'IS_EXIT_VARIABLE' not found in struct. A variable field the
    connected release does not have now reads as NULL; only the name is required.
    (#176)

Changed

  • [all] DuckDB 1.4.x LTS is no longer supported. Binaries on get.erpl.io are built for DuckDB v1.5.6;
    2.0 binaries are built and smoke-tested in CI. (#175)

v2026.10.21 — DuckDB 2.0

Choose a tag to compare

@jrosskopf jrosskopf released this 21 Oct 18:12
3c72a37

ERPL now builds on DuckDB 2.0.0 as well as v1.5.6 and v1.4.5 LTS, from one source tree. API differences
between the lines go through the header-only duckdb-compat helpers.
Verified against a live SAP system (ABAP trial) on all three lines: rfc, odp, bics and ape suites.

Changed

  • [all] Builds on DuckDB 2.0.0. The self-distributed set on get.erpl.io stays v1.5.6 and v1.4.5; 2.0
    binaries are built and smoke-tested in CI.
  • [rfc] On DuckDB 2.0, pushed-down predicates arrive as expression filters. They are now translated into
    RFC_READ_TABLE options; predicates SAP cannot express are evaluated locally. Before this, a 2.0 build would
    have returned unfiltered rows.
  • [rfc] Unknown required filter kinds are rejected when the scan starts instead of being ignored; optional
    filter hints (for example join Bloom filters) never drop rows.
  • [rfc] ATTACH on DuckDB 1.4.5: the lazy SAP catalog is re-read correctly after information_schema
    scans; AT (VERSION => …) on an attached SAP catalog is rejected.
  • [bics] duckdb_functions() reports the correct parameter names for every overload of
    sap_bics_describe on DuckDB 2.0.

Internal

  • [all] The C++ test targets (make cpp_tests_*) run again; three of the four never executed their tests.
  • [all] Versioned binaries on get.erpl.io are now published from release tags only (pull requests publish
    nothing; master updates latest).

Known limitations

  • [trampoline] The linux_amd64_musl binaries cannot load the SAP NetWeaver RFC SDK, which is glibc-only;
    the musl smoke test skips on every DuckDB line. This predates this release.

v2026.10.09 — structure members, flat and addressable

Choose a tag to compare

@jrosskopf jrosskopf released this 08 Oct 14:55
32662fe

The follow-ups to the hidden-members work of v2026.10.08, verified against a live BW system on the SAP
NetWeaver SDK and the erpl-proto backend.

Added

  • [bics] sap_bics_structure_members(query | cube, query | id => state): one row per structure member of a
    BEx query (structure, structure_technical_name, structure_text, structure_kind, element_uid, text,
    technical_name, position, visibility, in_selection), the flat form of the structures lists in
    sap_bics_describe (#164).
  • [bics] Structure members in sap_bics_describe and in the DESCRIBE return of the session functions carry
    in_selection: whether an include/equal entry of the structure's current selection selects the member, so the
    effect of sap_bics_hidden_members and sap_bics_filter is visible without a result fetch. true for every
    member of a selection without entries (BW shows all then); a selection holding only exclusions or ranges
    selects nothing; NULL in the design-time (cube, query) form (#163).

Fixed

  • [bics] A structure given by the technical name the query designer assigned to it is accepted by
    sap_bics_hidden_members and sap_bics_filter alike; BW reports that name as the structure's alternative name
    while its selection state keeps the element uid. Covered by the ZERPL_Q154_KF fixture (#165).

v2026.10.08 — hidden structure members, and hierarchy variables labelled right

Choose a tag to compare

@jrosskopf jrosskopf released this 08 Oct 06:36
fe9cf5e

Two BICS fixes reported by users of BEx queries, both verified against a live BW system on the SAP NetWeaver
SDK and the erpl-proto backend.

Added

  • [bics] sap_bics_hidden_members(state_id, structure, 'SHOW' | 'HIDE') shows, or hides again, the
    structure members a BEx query hides with "Hide (can be shown)", as Analysis for Office's "Show hidden
    members" does. BW hides such a member by leaving it out of the structure's initial selection; the function
    touches only those members, so a filter on the visible ones survives, and HIDE never leaves the selection
    empty (BW would show everything). sap_bics_filter(state, structure, '<element_uid>') shows one member at a
    time. Members defined as "Hide" are never reported by BW and stay hidden (#159).
  • [bics] sap_bics_describe reports each structure member's element_uid (the handle for the above) and
    its design-time visibility (VISIBLE / HIDDEN), from the query's meta data cells (#159).
  • [bics] A query state BW rejects (BICS_PROV_SET_STATE message type E or A, for example while a mandatory
    variable is unfilled) is reported with the state id, BW's messages and a way out, instead of silently
    producing the previous result. A mutation BW rejects is not persisted; a mutation BW accepted is, even when
    the fetch that follows fails (#159).
  • [build] make cpp_tests_<extension> builds and runs a sub-extension's Catch2 binary; they are not part of
    test/unittest and had no documented command.

Fixed

  • [bics] sap_bics_describe and sap_bics_variables reported hierarchy-node variables as HIERARCHY and
    hierarchy variables as HIERARCHY_NODE: the two labels were swapped (BW domain RSZVARTYP: 2 = hierarchy
    nodes, 5 = hierarchy). They also returned an empty reference_char for node variables, which BICS does not
    fill; it is now completed from RSZGLOBV-IOBJNM, read in batches that fit the RFC_READ_TABLE option row
    (#160).
  • [bics] A filter ADD next to a range or exclusion entry on the same value is no longer swallowed (#166).

v2026.10.02 — DuckDB v1.5.6

Choose a tag to compare

@jrosskopf jrosskopf released this 02 Oct 21:56
13435f5

The "latest" binary leg moves from DuckDB v1.5.5 to v1.5.6, the bugfix release of 2026-09-28. The
LTS leg stays on v1.4.5; upstream has no newer 1.4 release. No ERPL source changes were needed.

Changed

  • [all] Binaries for DuckDB v1.5.6 replace the v1.5.5 set on get.erpl.io. The download path is
    keyed by DuckDB version, so a DuckDB v1.5.5 install can no longer fetch this release or any later
    one. Upgrade DuckDB to v1.5.6, or stay on v2026.10.01, which was the last release built for v1.5.5.
  • [all] Verified on v1.5.6 before release: the four C++ suites, and the SAP-backed SQL suites of
    erpl_rfc, erpl_odp, erpl_ape and erpl_bics on both RFC backends, the SAP NetWeaver SDK and
    erpl-proto. The five platforms of both DuckDB versions build in CI.

v2026.10.01 — query sessions that behave like cube sessions

Choose a tag to compare

@jrosskopf jrosskopf released this 01 Oct 07:36
41d7501

A BEx query that has variables used to open into a session BW had already given up on:
BICS_PROV_GET_INITIAL_STATE answers with an abort and every table empty until the variable
container is submitted, and ERPL never submitted it. Everything that works from the session
state failed on such a query, though the same call worked on its cube. Reported in #154.

Fixed

  • [bics] sap_bics_rows, sap_bics_columns and sap_bics_filter work on a query that has
    variables.
    They failed with Characteristic with name 'X' not found although
    sap_bics_describe listed the characteristic. The variable container is now submitted when the
    session opens, so the state carries the query's characteristics, key figures and axes. This
    applies to any query with a variable container, including ones whose variables are all exit
    variables. Opening a query without its mandatory values still succeeds, and sap_bics_result
    still names the missing variable.
  • [bics] Structures can be moved between axes on those queries, for the same reason.
  • [bics] Row labels of a key figure structure are its member texts, not dyn_kf_N. Member
    ids repeat across structures, so a query with a key figure structure on rows and a
    characteristic structure on columns could label a row with a member of the other structure
    (Selection 2 instead of Billed Quantity). A member is now looked up inside its own structure.
  • [bics] sap_bics_describe(cube, query).variables returns the query's variables. It was a
    VARCHAR that was always NULL. It is now a LIST<STRUCT> with the fields of sap_bics_variables,
    and an empty list for a query without variables.
  • [bics] Sessions persisted by an earlier build for such a query are rebuilt on restore instead
    of carrying their empty state forward.

Changed

  • [bics] Row labels of queries with variables follow the display setting of the query, as
    they already did for cubes. 0D_FC_AE_CONDITION_Q0015 returned the keys FC001, FC010 and now
    returns the texts Anchor Inn, Pen. Anything that filters or joins on those keys needs
    sap_bics_set_char_prop(id, '<char>', 'DISPLAY', 'KEY'), which now works on a query state.

Added

  • [bics] A failed OLAP read is reported, not returned as NULLs. BICS_PROV_GET_RESULT_SET
    has no message table: when the read fails, BW only sets a severity and parks the messages on
    the server, and the result came back with every measure NULL. The messages are now fetched
    (RSBOLAP_BICS_GET_MESSAGES); an error with no data cells raises with BW's text, an error
    alongside cells is a warning in the trace.
  • [bics] Data cells that cannot be placed, cells placed with a NULL value, and rows that
    arrive without any cells are counted and logged with SET erpl_trace_enabled = true; SET erpl_trace_level = 'WARN'. Previously they vanished, which made a mapping problem look
    like a query with no data. The all-NULL result reported in #154 is not reproduced: on the
    trial system a key figure structure on rows and a characteristic structure with hidden
    members on columns returns correct cells (ZERPL_Q154_KF, a new committed BW query fixture,
    bics/test/fixtures/setup_q154_query.sh). A trace of the failing run would settle it.
  • [rfc] [bics] Every erpl function is discoverable from duckdb_functions() with a
    description, example and category, including the tunnel deprecation stubs and the 31 bw_*
    metadata views.

v2026.09.23 — CDS delta with deletes, through SAP's own pipeline engine

Choose a tag to compare

@jrosskopf jrosskopf released this 23 Sep 16:52

SAP Note 3255746 prohibits third-party use of the ODP-RFC modules, a security patch has enforced
that since 9 June 2026, and the temporary opt-out expires at the end of the year. The note names
CDS view extraction among the paths that remain permitted. This release is that path: erpl_ape
reads CDS entities through the ABAP Pipeline Engine — the runtime SAP Datasphere itself uses for
ABAP sources — and its delta reports deletes, which a change-timestamp delta structurally
cannot, because a deleted row has no timestamp left to move.

erpl_ape is now part of the erpl bundle, so LOAD erpl loads it beside erpl_rfc,
erpl_bics and erpl_odp. Nothing is installed in SAP: no transport, no Z objects, no ABAP.
Extraction on a customer system needs a role granted on the SAP side; ape/docs/security.md is
the handout and sap_ape_check_authorizations() verifies the result rather than asking anyone to
trust it.

Added

  • [trampoline] erpl_ape is now part of the bundle, so LOAD erpl extracts, installs
    and loads it alongside erpl_rfc, erpl_bics and erpl_odp. It built correctly before this
    and was simply never embedded: the trampoline hard-codes each sub-extension name in eleven
    places, and a module missing from those lists compiles, passes its own suite, and does not
    exist for anyone who types LOAD erpl. scripts/smoke-test.sh now asserts one function per
    bundled extension — it previously checked three, all from erpl_rfc, so it could not have
    caught this.

  • [rfc] sap_rfc_authorizations() gains the erpl_ape rows. Worth reading for one fact
    they make plain: the extraction functions reach SAP through only DHAPE_GRAPH_MANAGER and
    DHAPE_GRAPH_ROUNDTRIP no matter what the pipeline does, because the graph is driven by JSON
    rather than by distinct function modules. So S_RFC says nothing about which operators a user
    may run — that is per-operator via S_DHAPEOPR, which sap_ape_check_authorizations() probes.

  • [ape] New sub-extension erpl_ape — CDS entity extraction through SAP's own ABAP
    Pipeline Engine (DHAPE_*) and its metadata browser (DHAMB_*), with no ABAP footprint.
    Its source lives in the DataZooDE/erpl-ape submodule at ape/; the binary is bundled in
    the erpl trampoline, so LOAD erpl loads it like the other sub-extensions. Extraction
    against a customer system needs a role granted on the SAP side, which is normally agreed per
    engagement — ape/docs/security.md is the handout, and sap_ape_check_authorizations()
    verifies the result.

    • PRAGMA sap_ape_ping — logs on and asks the engine for its version, so it fails when the
      DHAPE_* function group is unreachable rather than only when logon fails.
    • sap_ape_system_info() — engine version, raw capabilities JSON, and a supported flag with a
      reason when false.
    • sap_ape_show() — CDS entities with release flag, base table and package. Browses only the
      /CDS subtree; the metadata browser's root also exposes /ODP_BW and /ODP_SAPI, and
      erpl_ape never reads those.
    • sap_ape_describe() — field list whose DuckDB types come from the same DDIC mapper
      sap_read_table uses, so the two agree cell for cell. Carries the currency/unit reference.
    • sap_ape_preview() — typed sample rows that start no graph and create no subscription.
    • erpl_ape_allow_unreleased setting (default off) for entities with no release contract.
    • sap_ape_read_delta() delta including deletes — verified end to end: insert and update
      arrive as after-images (/1DH/OPERATION = 'U'), a delete as 'D' carrying only its keys. That
      is the capability ODP's byElement annotation cannot provide.
    • sap_ape_read_full() / sap_ape_read_delta() — extraction through the pipeline engine, with
      projection and server-side filters pushed into the reader. filters uses the same
      {FIELDNAME, SIGN, OP, LOW, HIGH} struct as erpl_odp. Delta surfaces the engine's own
      per-row change indicator, /1DH/OPERATION, under that name rather than an invented one.
    • sap_ape_show_subscriptions() and PRAGMA sap_ape_drop(cds_name, subscriber_process) — the
      engine keeps subscriptions after a graph ends, so they need listing and erasing. There is no RFC
      for either; both run short-lived graphs built from the engine's own subscription-reader and
      subscription-eraser operators. sap_ape_read_full erases its own subscription when the scan
      ends, so a snapshot leaves nothing behind.
    • recover => true on sap_ape_read_delta, backed by a local spill in
      erpl_ape.delta_spill. The engine commits each portion as it hands it over and has no client
      acknowledgement — measured, abandoning a scan after 5 of 180 changes lost the other 175 — so
      there is nothing on the SAP side to re-stream and durability has to be local. The spill is
      written on its own transaction, so the rollback that loses your rows cannot discard it too.
      erpl_ape_spill_enabled = false opts out, at the cost of making delta at-most-once.
    • sap_ape_check_authorizations([cds_name]) — what SAP must grant and whether the
      connected user has it, probed live with AUTHORITY_CHECK. The requirement list is read
      off the system, and its values come from the ABAP classes that perform the checks rather
      than from TOBJ, which says which fields exist and nothing about what is passed to
      them. Read verdict: one row (S_DHAPEOP) is a grant the role must not hold, because
      it is the fallback that overrides S_DHAPEOPR and silently defeats the operator
      restriction. The list doubles as the module's CDS-only posture in a form a Basis team can
      verify — S_DHAPEOPR is checked per operator name by CL_DHAPE_OPERATOR_REGISTRY, and
      the browser's SLT / ODP_SAPI / ODP_BW / table / view objects are absent by design.
      ape/docs/security.md carries the ZERPL_APE role definition and handout, and
      ape/docs/protocol.md records the class and call site behind every row.
    • erpl_ape_prepare_timeout bounds the wait for SAP's asynchronous preparation, and
      erpl_ape_delta_quiet_seconds bounds how long an already-established delta subscription waits
      for a first package before reporting that there is nothing to replicate. They are separate on
      purpose: a resumed subscription is already prepared, so minutes of waiting for "no changes"
      would be absurd, while a couple of seconds reports "no changes" when the answer is "not yet".
    • The set of pipeline operators the module will drive is compiled in; no setting widens it, and
      the reader is restricted to CDS containers.

Changed

  • [rfc] SAP_* environment variables no longer seed extension settings.
    RfcEnvironmentCredentialsProvider set six sap_* options that were never registered and never
    read — credentials come from secrets — so merely having SAP_PASSWORD exported crashed extension
    load with INTERNAL Error: Unrecognized option sap_password. The provider is removed rather than
    registered. If you relied on SAP_ASHOST/SAP_USER/SAP_PASSWORD being picked up implicitly,
    create a secret instead. The suites never caught this because they use ERPL_SAP_* names.

  • [ape] Subscriptions erpl_ape registers are named ERPL_ + your subscriber_process. The
    engine records no usable creator, so the name is the only way the module can recognise its own —
    which is what lets sap_ape_show_subscriptions() default to "ours" without hiding the durable
    delta subscriptions a caller named itself (previously the default listing showed only the
    ephemeral snapshot ones). You never spell the prefix out: sap_ape_read_delta and
    PRAGMA sap_ape_drop take the plain value, and the listing reports it unprefixed alongside the
    new subscription_name column carrying the stored form. The prefix is matched case-sensitively, so
    a third party's erpl_x is not treated as ours. Subscriptions from an earlier build carry the
    bare name:
    drop falls back to it, and a delta read that finds one refuses rather than silently
    registering a second subscription and re-running the initial load.

  • [ape] recover => true no longer contacts SAP at all. It used to resolve the entity
    against the catalogue at bind time, so it failed exactly when SAP was unreachable — the situation
    it exists for. The schema now comes from the spilled package plus the column names recorded with
    the batch, so a replay reports the same columns as the read it replaces.

  • [ape] The spill's payload column is now BLOB. A package whose bytes are not valid UTF-8
    — ordinary for SAP text in a non-UTF-8 codepage — used to abort the scan after the engine had
    committed the portion, and the error carried the whole package. An existing spill table with a
    VARCHAR payload is reported with the DROP TABLE to run rather than silently misused.

  • [ape] A value that will not convert raises instead of becoming NULL. The documented wire
    sentinels (9999-99-99, NaN, …) map to NULL deliberately, but only where the column cannot hold
    them — in a text column ? and NaN are data. Anything else names the package, row, column and a
    bounded fragment of the text. A silent NULL is a wrong answer the caller cannot see. Likewise a
    column the catalogue reports but the package does not carry is an error, not a column of NULLs.

  • [ape] An entity named by its metadata-browser path (/CDS/TMP/ZERPL_APE_D) now resolves to
    the bare name the engine stores, so a delta read spelled that way resumes instead of failing on
    its second call with "subscription already exists".

  • [ape] wireformat is validated against the four profiles the reader declares, and
    recover => false on a full read no longer raises (only a true value is refused).

Notes

  • [ape] Server-side filters are refused, not ignored, and projection is applied on the
    client.
    ...
Read more

v2026.09.16 — Custom RFC_READ_TABLE support, configurable delimiters, and bind-time secret validation

Choose a tag to compare

@jrosskopf jrosskopf released this 16 Sep 04:06

Added

  • [rfc] Custom RFC_READ_TABLE replacement function support (issue #145).
    Users can now configure an alternate SAP read table function module (e.g. /SAPDS/RFC_READ_TABLE2, /BODS/RFC_READ_TABLE2, or custom customer Z_*//MYNS/* modules) to read tables and CDS views.
    Resolution follows a 5-tier independent precedence hierarchy: query named parameter > ATTACH option > DuckDB secret option > session setting > built-in default (RFC_READ_TABLE).
    Includes function signature introspection validating input/output table contracts at bind time. Reading string/xstring columns requires an ET_DATA-capable reader (such as standard RFC_READ_TABLE with SAP Note 2246160 or a custom module declaring ET_DATA).
  • [rfc] Configurable delimiter for read table functions.
    Configurable via READ_TABLE_DELIMITER independently across all configuration tiers, validated as a single printable non-whitespace ASCII character (defaulting to ~ on ET_DATA reads when empty). Per-query explicit empty string (READ_TABLE_DELIMITER='') clears lower-tier delimiters.
  • [bics] Custom read table function and delimiter support for BICS query execution.
    sap_bics_query and sap_bics_query_cube consume session and secret reader function settings with interface validation, failing fast if the configured reader lacks DELIMITER parameter support. (Note: BICS catalog scanners sap_bics_meta_* currently retain standard RFC_READ_TABLE).
  • [odp] Shared read table function and delimiter resolution.

Changed

  • [rfc] Named secret validation moved to bind time.
    When specifying secret = 'secret_name' in sap_read_table, sap_show_tables, or related functions, secret existence and type compatibility (TYPE sap_rfc or TYPE sap) are now validated at bind time instead of deferring to connection open.
  • [rfc] String/Xstring reader requirements clarified.
    Standard SAP Data Services readers (/SAPDS/RFC_READ_TABLE2, /BODS/RFC_READ_TABLE2) provide wide table buffers (TBLOUT30000) rather than deep ET_DATA string support. Unreachable string fallback candidates have been removed. Systems reading ABAP deep strings require RFC_READ_TABLE with SAP Note 2246160 or a custom reader declaring ET_DATA.
  • [bics] Default delimiter alignment.
    BICS DDIC metadata extraction now defaults to ~ (matching sap_read_table) when no delimiter is explicitly configured.

v2026.09.04 — scans that can be run twice, and a backend with no known gaps

Choose a tag to compare

@jrosskopf jrosskopf released this 04 Sep 09:41

sap_read_table gains row-range partitioning, and the three extensions gain one tuning
vocabulary. The reason this is one release rather than two is the second half of the list:
four separate silent wrong-results defects, all in released erpl, all returning data
rather than failing.

The sharpest is that a re-scanned sap_read_table returned nothing at all — a prepared
statement, a nested-loop join or an un-materialised CTE referenced twice would silently
answer zero rows on the second scan. If you use erpl from a prepared statement or in a
join, upgrade.

The erpl-proto backend also passes every suite with no recorded gaps for the first time.

Added

  • [rfc] sap_read_table can now split a scan by rows. Parallelism was per
    column — one concurrent RFC_READ_TABLE call per projected column — so a narrow
    extract got none at all, and raising threads did nothing. partitions hands each
    worker a row window read with ROWSKIPS/ROWCOUNT. Measured on a 164,664-row
    single-column extract: 2.23s unpartitioned, 0.83s at eight partitions (2.7x),
    with the knee visible at eight. Opt-in, because partitioned workers finish in
    whatever order they finish while an unpartitioned scan returns rows sorted.

  • [rfc] erpl_rfc_partitions and erpl_rfc_partition_window_rows, plus a
    partitions named parameter.

  • [rfc] One tuning vocabulary across the extensions. Paging and parallelism were
    spelled differently everywhere: RFC had THREADS plus erpl_rfc_read_table_batch_budget,
    ODP had threads and no settings at all, BICS had neither. threads /
    erpl_rfc_max_threads and fetch_size / erpl_rfc_fetch_size now mean the same thing
    wherever they appear, and fetch_size is settable per query rather than per session.
    No breaking renames — erpl_rfc_read_table_batch_budget still works and writes the same
    value.

  • [odp] erpl_odp_fetch_size and erpl_odp_max_threads, ODP's first settings.
    I_MAXPACKAGESIZE was compiled in at 2 MiB and reachable from nowhere, so round-trips
    could not be traded against per-packet memory.

  • [bics] sap_bics_begin honours its rows, columns and filters parameters.
    They were declared and never read — accepted with no error and no effect. Building a
    query this way also costs three fewer full session round-trips.

  • [rfc] sap_rfc_live_connections(), sap_rfc_connections_opened() and
    sap_rfc_connections_closed() report how many SAP RFC connections erpl has opened,
    closed and still holds. Between queries the live count should be 0 — a non-zero value
    means SAP sessions are still reserved, which client-side timing cannot reveal.

Fixed

  • [odp] PRAGMA sap_odp_close_delta_cursor never closed anything. It matched the
    cursor on (SUBSCRIBER_PROC, QUEUENAME) and took the first row, but SAP retains every
    closed cursor as history, so that pair routinely has a dozen rows — the open one was
    found at position 7 behind six closed rows from previous days. The pragma reported
    'CLOSED' without ever calling RODPS_REPL_ODP_CLOSE, so delta cursors accumulated
    server-side while cleanup looked like it was working.

    Two more defects sat in the branch that made unreachable: every exception was reported
    as 'CLOSED', and the call's ET_RETURN was never read — RODPS_REPL_ODP_CLOSE returns
    RFC_OK even when it refuses, so a rejected close was indistinguishable from a
    successful one. Behaviour change: two new results, neither of which raises —
    'REFUSED: <SAP message>' when SAP rejects the close (typically
    ILLEGAL_REQ_STATE_FOR_CONFIRM, meaning the request was left mid-fetch and only
    sap_odp_drop will clear it) and 'STILL_OPEN' when the cursor survives a call that
    reported no error.

  • [odp] sap_odp_read_full crashed at threads := 8 on a source with fewer packages
    than workers — a null local state, dereferenced unconditionally.

  • [bics] The result-size refusal message stated what a query would really cost. BICS
    memory scales with result rows, not data cells, so the cell-derived figure it used
    to quote understated a 46,755-row result by 19x — and suggested raising a setting that
    would have let the query through and then run the process out of memory.

  • [rfc] sap_rfc_invoke failed on any module whose result parameters are all
    tables.
    RFC_READ_TABLE is the canonical case — its results are DATA, FIELDS
    and OPTIONS, with no scalar export — and invoking it raised
    Unimplemented type for cast (STRUCT(WA VARCHAR) -> STRUCT(WA VARCHAR)[]).

    The result was treated as pivoted whenever every value happened to be list-shaped,
    so rows were unnested into columns still declared LIST(STRUCT). Detection now also
    requires each element type to match its declared column type, which distinguishes
    genuinely pivoted (path-selected) data from a bare invoke. Selecting a table through
    path := still pivots to the row's fields, as before.

  • [rfc] MAX_ROWS combined with partitions hung. The unpartitioned path trims
    ROWCOUNT to land exactly on the limit, which a partitioned window cannot do because
    ROWCOUNT must stay batch-aligned; it over-fetches the final batch, and the clip then
    left the read spinning with rows it would never emit.

  • [rfc] The runtime RFC_READ_TABLE fallback reassigned a std::string on the
    bind data from execute time. Column-parallel reads already made that reachable from
    two tasks at once; it is now serialised.

  • [rfc] fetch_size and partitions did nothing to the batch size of a
    single-column scan.
    MaxBatchSizeForColumnCount returned the full 32768-row cap
    whenever a scan projected one column, discarding the budget that
    ResolveEffectiveMaxBatchSize had just divided across the partition workers — so every
    worker asked SAP for ROWCOUNT=32768 however erpl_rfc_fetch_size and partitions
    were set. The exemption was deliberate, on the reasoning that a narrow scan is already
    under any sane budget; that reasoning ignored the division, and a narrow scan is
    precisely what partitioning exists for.

    Measured on a 300,000-row single-column read at partitions = 8: peak RSS 405 MB →
    307 MB (−24%)
    with no loss of throughput (2.17s → 2.07s). The budget now binds for
    every column count; only a zero budget or a scan with no projected column bypasses it.

  • [rfc] A partitioned scan never returned its allocator arenas to the OS. The serial
    path calls malloc_trim(0) when the scan finishes, but each partition worker retires on
    a different code path that did not, so every worker thread's glibc arena kept its
    high-water mark — which is what getrusage reports.

  • [rfc] A partitioned scan past the ROWSKIPS ceiling returned a truncated result
    instead of refusing.
    The row-window scheduler signalled the ABAP INT4 limit by
    returning "no more windows", which is the same answer it gives at the end of a table —
    and a worker retires on an empty chunk, which DuckDB reads as end-of-scan. A scan beyond
    2,147,483,647 rows therefore produced a silently short answer, while API_REFERENCE
    states that erpl refuses rather than wrapping. It now raises, naming the limit.

    The same guard was off by one and refused the last legal window (start
    2,147,450,880 at a 32768-row window). Both are covered by new boundary tests.

  • [rfc] The RFC_READ_TABLE fallback could retry without limit. After the runtime
    fallback had switched functions, the selection call returns a cached success, and the
    retry branch neither counted the attempt nor slept — so a second TABLE_WITHOUT_DATA
    from the fallback function became a tight loop against the SAP system, once per
    partition worker. It now retries only when the selected function actually changed, and
    otherwise reports the original error.

  • [rfc] A re-scanned sap_read_table silently returned nothing. The column state
    machines lived in bind data, which DuckDB reuses across executions of one bound plan,
    so the second scan resumed from an exhausted cursor:

    PREPARE q AS SELECT count(*) FROM sap_read_table('SFLIGHT');
    EXECUTE q;   -- 94
    EXECUTE q;   --  0   <- no error

    Any re-scanned plan hit it: a prepared statement, a nested-loop join, an
    un-materialised CTE referenced twice. Serial scans now build their machines in the
    global state, which DuckDB rebuilds per execution — the pattern the partitioned path
    already used, which is why PARTITIONS was never affected.

    The same defect was present in sap_show_tables, sap_odp_show_subscriptions and the
    internal table lister behind ATTACH; all three are fixed.

  • [rfc] The persistent-connection budget was spent permanently.
    erpl_rfc_max_persistent_connections was a monotonic counter on bind data that never
    released a slot, so a second execution of a bound plan began with the budget already
    exhausted and every scan fell back to per-batch open/close. Slots are now leased:
    released when the connection is dropped, reset per execution.

  • [rfc] A long scan could follow a secret replaced underneath it. The DuckDB
    secret was re-resolved on every connection open, so replacing it mid-query could send
    later windows of the same scan to a different SAP system, with no error. Credentials are
    now resolved once per execution.

  • [rfc] Setting a trace option while tracing was enabled deadlocked the process.
    erpl_trace_level, erpl_trace_output and the other setters logged their own change
    while holding the tracer mutex, which the writer re-locks. The sequence documented for
    diagnosing SAP communication was itself the trigger; it presents as a hung query.

Changed

  • [all] The erpl-proto backend is pinned to v2026.9.2.1, and its known-failure
    list is now empty.
    The previous pin carried a table-delta padding gap
    (`sap_rfc_...
Read more