We have a scenario where some reference data is getting ingested in a Kusto table (~1000 rows).
To handle data duplication due to daily data load (as Kusto does always append), we have created a Materialized view(MV) on top of the table to summarize the data and get the latest data based on ingestion_time(), so that querying the MV will always result in latest updated reference data.
Our next ask is to export this formatted data in a storage container using Kusto continuous data export (please refer MS doc), however, it seems we can't use Materialized view to set up a continuous export.
So looking at options, is there any way we can create a truncate load table instead of a Materialized View in kusto, so that we don't have a duplicate record in the table and it can be used to do continuous export.
.create async materialized-view with (backfill=true) products_vw on table products
{
products
| extend d=parse_json(record)
| extend
createdBy=tostring(d.createdBy),
createdDate = tostring(d.createdDate),
product_id=tostring(d.id),
product_name=tostring(d.name),
ingest_time=ingestion_time()
| project
ingest_time,
createdBy,
createdDate,
product_id,
product_name
| summarize arg_max(ingest_time, *) by product_id
}
You can use Azure logic app or Microsoft flow to run the applicable export command to an external table backed by Azure storage on any given time interval. The query can simply refer to the materialized view, for example:
.export to table ExternalBlob <| Your_MV