We have a on-premise gateway configured which allows us to connect to our local databases without a problem.
However, the issue lies when we attempt to connect to our Azure SQL databases to retrieve data, more specifically to any other connections that we have set up. We have discovered that when using any of the SQL Server type actions, even after we specify the connection of that action to point to use the connection to Azure SQL, the connection that is always used is the one we have set up for the on-premise database.
We are not sure if this is specific to the on-premise gateway or the fact that in our configurations, this was the first connection that appears on "My connection" list under the action. It seems that the bug here is that the first connection in the list will be called no matter what the case.