Wednesday, February 26, 2020

Avoid "Attempting to access memorized transaction as a non-memorized transaction" when doing a search via Web Services.

User receives "Attempting to access memorized transaction as a non-memorized transaction" when performing Web Services search operation. One possible way to avoid this is to set Memorized = false on search filter, see sample SOAP request below:

<soap:Body>
    <platformMsgs:search>
      <platformMsgs:searchRecord xsi:type="tranSales:TransactionSearch">
        <tranSales:basic>
          <platformCommon:mainLine>
            <platformCore:searchValue>true</platformCore:searchValue>
          </platformCommon:mainLine>
          <platformCommon:memorized>
            <platformCore:searchValue>false</platformCore:searchValue>
          </platformCommon:memorized>

          <platformCommon:status operator="anyOf">
            <platformCore:searchValue>_invoiceOpen</platformCore:searchValue>
          </platformCommon:status>
          <platformCommon:type operator="anyOf">
            <platformCore:searchValue>_invoice</platformCore:searchValue>
          </platformCommon:type>
        </tranSales:basic>
      </platformMsgs:searchRecord>
    </platformMsgs:search>
  </soap:Body>

 

No comments:

Post a Comment