IBM / nodejs-idb-connector

A JavaScript (Node.js) library for communicating with Db2 for IBM i, with support for queries, procedures, and much more. Uses traditional callback-style syntax
MIT License
38 stars 23 forks source link

fix: stop returning nulls #170

Closed abmusse closed 5 months ago

abmusse commented 1 year ago

When returning a result set from RPGLE External SQL Stored Procedure, nulls are being returned in the fields that are returned.

Documented recreating the customer issue in: https://github.com/IBM/nodejs-idb-connector/issues/169#issuecomment-1592214085

Documented Suggested code changes in: https://github.com/IBM/nodejs-idb-connector/issues/169#issuecomment-1592218433

Another possible solution would be to set SQL_ATTR_INCLUDE_NULL_IN_LEN to SQL_FALSE

image

I'm not sure how this would adversely affect the rest of the code base though. So for now reverting back to what we had before the changes in https://github.com/IBM/nodejs-idb-connector/commit/56d66e7faab1a8fd61ccb6971a3555723d8a63a5 (This added the rlength if condition) which seems to make the most sense at this time.

Fixes https://github.com/IBM/nodejs-idb-connector/issues/169

github-actions[bot] commented 11 months ago

:wave: Hi! This pull request has been marked stale due to inactivity. If no further activity occurs, it will automatically be closed.