If one more output parameter is there in Execute command so we can send the value of last updated ID or number of updated records in that output variable.
Hi Madhuri,
I understand your need, but I think OutSystems' vision for Advanced SQL nodes is that they are meant to retrieve data from the database only and not be used to write data to it. If you want to implement the use case you mentioned, you will do it with a For Each loop and variables to store the last updated ID and the number of updated records.
That said, I don't think your idea will be implemented any time soon.
Kind regards.
Hi @Ricardo Reis,
Why do you assume that AdvancedSQL is only for retrieve? It can be perfectly used for insert, update and delete, especially for bulk insert, update and delete SQL actions.
Regards,
Daniel
Why not provide that output parameter yourself, what is the benefit of OutSystems providing this?
Hi Daniel,
Advanced SQL nodes can indeed be used for write operations (and there's OutSystems documentation articles about that), but I think their main purpose is to retrieve data. I was thinking about that in my previous reply.
Regards.
I don't agree, their main purpose is do what aggregates or crud actions can not do or not do efficiently, like advanced SQL features like IN and subselects, or bulk insert, updates and deletes.
Fair enough. I agree with you.
@Daniel Kuhlmann Thank you for your comments.
You are right we use Advanced SQL to migrate data from temporary table to another table .
we are doing this in batches but in case if record is not inserted due to any special character or data type validation issues with any record. I would not get result like how much data is actually migrated from that batch . As after insertion i marked that record as "Migrated" in Temporary table.As I don't have any output parameter to know about that. Added some extra code or logic to find out till which data is migrated. this sort my issue but it impacts on my performance that's why this point I raised here.Also if you check below screenshot there is no any way to give output parameter