Yes, it is possible to connect to onprem SQL from the azure function. You can refer to this document to create the hybrid connection and how it works. The hybrid connection is not supported in Consumption Plan and works with Windows OS for azure function with other plans as mentioned in this article. You need to create the function app under the app service plan.
Reference: https://learn.microsoft.com/en-us/azure/azure-functions/functions-networking-options#matrix-of-networking-features
Please 'Accept as answer' and ‘Upvote’ if it helped so that it can help others in the community looking for help on similar topics.
