A remote method that calls DATASNAP+FIREDAC sometimes executes two sql or stored procedure bugs
1) The situation where the query will be repeated:
Result: = Datasetprovider. Data triggers its associated dataset to execute a query
Fdquery. Close;
Fdquery.sql.Clear;
Fdquery.sql.Text: = SQL;
D.qryopen.open; This line code must be commented out, otherwise SQL will be executed two times
Result: = Datasetprovider. Data; This row will also trigger a fdquery query
2) The situation where the stored procedure will be executed repeatedly:
Result: = Datasetprovider. Data triggers its associated TFDSTOREDPROC and executes the stored procedure again
Tfdstoredproc.open; This line code must be commented, or the stored procedure will be executed two times
Result: = Datasetprovider. Data; This row will trigger the execution of the stored procedure again
Hint: The wing South Middleware has fixed this bug.
A remote method that calls DATASNAP+FIREDAC sometimes executes two sql or stored procedure bugs