簡體   English   中英

SSAS表格-僅處理新的或已修改行的數據

[英]SSAS Tabular - Only process data where row is new or modified

我有一個SSAS多維數據集,可從源系統導入數據視圖。 每次執行此處理時,它都會導入完整視圖,但是我想通過僅處理自上次處理以來新的或已更改的行來提高性能。 誰能建議最好的方法?

該視圖具有一個ID列以及創建日期和修改日期(如果有幫助)?

即使在谷歌搜索后也不知道嘗試什么

您的模型處理策略是什么? 您為什么要進行Process Full

有一個稱為Process Add的選項,它根據條件允許只加載尚未在多維數據集中配置的新數據,該條件使您可以分割所有未在模型中添加的已修改數據。

這是流程添加邏輯的簡短片段:

[Reflection.Assembly]::LoadWithPartialName("Microsoft.AnalysisServices")
$server = New-Object Microsoft.AnalysisServices.Server
$server.connect("localhostK12")
$db = $server.Databases.Item("AdventureWorks Tabular Model SQL 2012")
$dsv = $db.DataSourceViews.GetByName("Sandbox")
$cube = $db.Cubes.GetByName("Model")
$measureGroup = $cube.MeasureGroups.GetByName("Internet Sales")
$partition = $measureGroup.Partitions.GetByName("Internet Sales")
$queryBinding = New-Object Microsoft.AnalysisServices.QueryBinding( $dsv.DataSourceID, "SELECT * FROM FactInternetSales **WHERE OrderDateKey >= 20120215**" )
$partition.Process( "ProcessAdd", $queryBinding )
$server.Disconnect()

使用以下查詢過濾最近修改的記錄

    Select * from table where id, 
     modified_date IN (select id, 
      max(modified_date) from 
    table  group by id) or created_date IS 
        NULL;

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM