stefanopog/node-red-contrib-dominodb

Unexpected result with msg.DDB_queryOrId

JSG1901 opened this issue · 3 comments

When the Get Document node is set to retrieve by Query or docunid the DQL query or Doc ids field is visible and editable. However, when you select "-- set from msg.DDB_queryOrId" that field is hidden from view and, of course, NOT editable.

The catch is, (a) the value in that field is never cleared and (b) the code gives it precedence over what comes into GetDocument with the msg.DDB_queryOrId value.

This can be very confusing. If you have previously entered a fixed DQL query--maybe while working bugs out of the rest of your code--and neglect to delete it before changing to use the msg.DDB_queryOrId, it is frustratingly possible to have code and a node configuration that looks valid, and yet doesn't work properly.

I suggest a change to the following: When "--set from msg.DDB_queryOrId" is selected, the value(s) in the DQL Query and/or the Doc ids fields are simply ignored. Leave the values in place in case the change was erroneous or the user wishes to revert to an earlier setting, but ignore the contents for processing.

dcacy commented

Agreed. @stefanopog is this something you can address?

Yes, i am going to fix this in the next iteration next week.

fixed in version 1.0.0