Share via

Update Policy Function

Bexy Morgan 260 Reputation points
2023-10-17T14:59:16.9666667+00:00

Using update policy function, ingest data from source tables SourceTableA,SourceTableB,SourceTableC into Target table.

.create table SourceTableA (PK:string,A1:string,A2:int)
.create table SourceTableB (PK:string,B1:string,B2:int)
.create table SourceTableC (PK:string,C1:string)

.ingest inline into table ["SourceTableA"] <|
"ABC","Q",88
"DEF","W",11

.ingest inline into table ["SourceTableB"] <|
"ABC","Al",100
"DEF","Md",1111
"FGH","Bd",9824

.ingest inline into table ["SourceTableC"] <|
"ABC","Quad"
"FGH","Tex"


.create table Target (PK:string,A1:string,A2:int,B1:string,B2:int,C1:string)

Azure Data Explorer
Azure Data Explorer

An Azure data analytics service for real-time analysis on large volumes of data streaming from sources including applications, websites, and internet of things devices.


1 answer

Sort by: Most helpful
  1. Sander van de Velde | MVP 37,066 Reputation points MVP
    2023-10-17T17:09:50.09+00:00

    Hello Bexy,

    You want to ingest data from three different (source) tables into one (target) table.

    A (target) table can have multiple update policies.

    Follow this blog post regarding adding a (one) update policy.

    Just give your target table three separate update policies, each for another source table with a custom update policy function.

    So you probably need three functions.

    All (three) functions receive messages from their source table and need to honor the target table format.


    If the response helped, do "Accept Answer". If it doesn't work, please let us know the progress. All community members with similar issues will benefit by doing so. Your contribution is highly appreciated.

    Was this answer helpful?


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.