catalyst / moodle-tool_dataflows

A generic workflow and processing engine which can be configured to do a large variety of tasks.
GNU General Public License v3.0
13 stars 8 forks source link

sql reader is not setting query result variables #536

Open marcghaly opened 2 years ago

marcghaly commented 2 years ago

In the following dataflow, trying to use output mapping for the sql reader will not work as the result of the query is not set

Screenshot from 2022-08-10 11-55-55

Instead of manually entering the integer representing the student role, retrieving it from db would be a better option in case it ever changes

Screenshot from 2022-08-10 12-00-17

Screenshot from 2022-08-10 11-56-06

brendanheywood commented 2 years ago

This looks to me like you want to use an sql flow step as a once off connector step and just save it's output into a step variable rather than the flowing record. I think that is a perfectly valid business case and we can either implement a second sql connector step in the mean time before https://github.com/catalyst/moodle-tool_dataflows/issues/422 is implemented which I am expecting to be a fairly large internal refactor.

If this is blocking then lets just clone the sql flow step into a sql connector step for the time being and we can merge them later.