Scenario:
Gallery or datatable is displaying Items based on Filter('[dbo].[SomeSQLView]').
A Patch() is executed on another datasource '[dbo].[SomeSQLTable]'. This patched data source is a table that is part of SomeSQLView.
After the Patch() executes there is a Refresh('[dbo].[SomeSQLView]'), but the new data returned does not reflect the change just made by Patch() so Gallery does not reflect latest change.
I can add a button that will execute the Refresh('[dbo].[SomeSQLView]') to the screen and keep clicking it manually and not see the data change reflected for some time maybe 30 seconds.
Meanwhile I am confirming via SQL Management Studio that patched data was changed immediately in target table.
A current partial work around is to bind UI elements to collections that are based on datasource and then update the collections in parallel to patching datasources which works well and saves time waiting for Refresh() to run. But in some scenarios the SQL views are returning columns that are complex calculations that we do not want to try and duplicate in the App when modifiying collections.
The App does have 50 datasources referencing different tables and views from one SQL database.
Please let me know how I can successfully show updated data after it has been patched in this type of scenario.
Thanks!