Get related data from Azure Function using SQLTrigger?

Greg Smith 15 Reputation points

Hi, I have an Azure function that is running a SqlTrigger. When the trigger fires, we get a list of SQLChange<CourseStudent>, and CourseStudent is defined by the model below:

    public partial class CourseStudent
        public string StudentId { get; set; }

        public Guid CourseId { get; set; }

        public virtual Course Course { get; set; } 


Is there any way to have the foreign-key related data (Course, in this case) populate so it can be read when reading the list of CourseStudent? I'm not sure if there is any config for this, but the documentation doesn't mention anything.

Azure Functions
Azure Functions
An Azure service that provides an event-driven serverless compute platform.
4,353 questions
{count} votes

1 answer

Sort by: Most helpful
  1. MuthuKumaranMurugaachari-MSFT 22,156 Reputation points

    Greg Smith Sorry for the delay in our response. It looks like you already got the answer from our product team via discussion. Sharing it here for the benefit of the community. If you face any issues, feel free to reach out to us and thanks again for posting it in Microsoft Q&A.

    Answer from PG:

    Currently no, not directly at least. Using an input binding would be an option - although that would require either setting up another function that the one with the sql trigger calls (passing it the appropriate information from the trigger) or using imperative bindings for C# functions to dynamically call the input binding.

    0 comments No comments