SQL Reference
The canonical, source-verified function reference now lives at ERPL Function Reference.
For deeper protocol guides:
- RFC Protocol Guide — reading SAP tables and calling RFC functions
- BICS Protocol Guide — SAP BW queries, hierarchies, lineage
- ODP Protocol Guide — cursor-based delta extraction
- ERPL-Web docs — HTTP, OData, SAP Datasphere, Microsoft 365, Microsoft Dynamics 365
For pragma functions specifically:
- Pragma function reference —
PRAGMA sap_rfc_ping, trace configuration, INI management
Connection model
ERPL stores SAP credentials as a DuckDB secret. The connection is established lazily on the first call.
CREATE SECRET my_sap (
TYPE sap_rfc,
ASHOST 'sap-server.com',
SYSNR '00',
CLIENT '100',
USER 'username',
PASSWD 'password',
LANG 'EN'
);
-- Validate the connection
PRAGMA sap_rfc_ping;
-- Use it
SELECT * FROM sap_read_table('KNA1', MAX_ROWS => 100);
Multiple secrets coexist; pass SECRET => 'my_sap' to any ERPL function to select one explicitly. Connection pooling is automatic.