The error itgenjdn003
was reproduced using:
select *
from PayrollAdministrationPayrollRuns prn
join LoketNlRest.PayrollRunDownloads.TotalSepaFileByPayrollRunId(prn.prn_id, 'Salary', 'BtchBookgTrue', to_char(prn.prn_payrollPeriod_periodStartDate, 'YYYY-MM-DD'))
where prn.prn_payrollperiod_year=2014
limit 5
The expected column is DOCUMENT
as checked by:
select name
from systemtablecolumns@datadictionary
where table_name='TotalSepaFileByPayrollRunId'
The actual XML-document is returned as XML
column name with contents such as:
<?xml version="1.0" encoding="utf-8"?>
<Document xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:iso:std:iso:20022:tech:xsd:pain.001.001.03">
<CstmrCdtTrfInitn>
<GrpHdr>
<MsgId>46-99999-99</MsgId>
<CreDtTm>2022-03-23T12:49:24</CreDtTm>
<NbOfTxs>2</NbOfTxs>
<CtrlSum>1.1</CtrlSum>
<InitgPty>
<Nm>ACME BV</Nm>
</InitgPty>
</GrpHdr>
<PmtInf>
...
</PmtInf>
</CstmrCdtTrfInitn>
</Document>
But the metadata of Loket specifies that the payload should be named DOCUMENT
in this specific case. An alternation has been implemented for this.
Currently, the metadata also specifies a BLOB and not a CLOB. This is subject to further research. However, research is currently awaiting additional scopes being assigned to the client IDs.