analytics/pbi/report/Model/tables/Я.Директ расходы.tmdl
2026-02-22 15:39:05 +03:00

134 lines
4.1 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

table 'Я.Директ расходы'
measure 'Клики директ' = CALCULATE(SUM('Я.Директ расходы'[Клики]), ALL('Я.Директ заказы'[ID покупки]))
formatString: #,0
measure 'Показы директ' = CALCULATE(SUM('Я.Директ расходы'[Показы]), ALL('Я.Директ заказы'[ID покупки]))
formatString: #,0
measure 'Расходы директ, руб' = CALCULATE(SUM('Я.Директ расходы'[Расходы, руб]), ALL('Я.Директ заказы'[ID покупки]))
formatString: #,0
column Дата
dataType: dateTime
isHidden
formatString: Long Date
summarizeBy: none
sourceColumn: Дата
changedProperty = IsHidden
annotation SummarizationSetBy = Automatic
annotation UnderlyingDateTimeDataType = Date
column Кампания
dataType: string
summarizeBy: none
sourceColumn: Кампания
annotation SummarizationSetBy = Automatic
column Группа
dataType: string
summarizeBy: none
sourceColumn: Группа
annotation SummarizationSetBy = Automatic
column 'Условия показа'
dataType: string
summarizeBy: none
sourceColumn: Условия показа
annotation SummarizationSetBy = Automatic
column 'N условия показа'
dataType: string
summarizeBy: none
sourceColumn: N условия показа
annotation SummarizationSetBy = Automatic
column Показы
dataType: int64
isHidden
formatString: 0
summarizeBy: sum
sourceColumn: Показы
changedProperty = IsHidden
annotation SummarizationSetBy = Automatic
column Клики
dataType: int64
isHidden
formatString: 0
summarizeBy: sum
sourceColumn: Клики
changedProperty = IsHidden
annotation SummarizationSetBy = Automatic
column 'CTR, %'
dataType: double
summarizeBy: sum
sourceColumn: CTR, %
annotation SummarizationSetBy = Automatic
annotation PBI_FormatHint = {"isGeneralNumber":true}
column 'Расходы, руб'
dataType: double
isHidden
formatString: #,0
summarizeBy: sum
sourceColumn: Расходы, руб
changedProperty = IsHidden
annotation SummarizationSetBy = Automatic
column key_dir
dataType: string
isHidden
summarizeBy: none
sourceColumn: key_dir
changedProperty = IsHidden
annotation SummarizationSetBy = Automatic
column 'Ср. цена клика, руб'
dataType: double
summarizeBy: sum
sourceColumn: Ср. цена клика, руб
annotation SummarizationSetBy = Automatic
annotation PBI_FormatHint = {"isGeneralNumber":true}
partition 'Я.Директ расходы' = m
mode: import
source =
let
Источник = Sql.Database("prdsql", "mag_pbi"),
pbi_direct_adv_costs = Источник{[Schema="pbi",Item="direct_adv_costs"]}[Data],
#"Измененный тип" = Table.TransformColumnTypes(pbi_direct_adv_costs,{{"Дата", type date}}),
#"Добавлен пользовательский объект" = Table.AddColumn(#"Измененный тип", "Пользовательский", each [#"Расход, руб"]/1000),
#"Переименованные столбцы" = Table.RenameColumns(#"Добавлен пользовательский объект",{{"Пользовательский", "Расходы, руб"}}),
#"Удаленные столбцы" = Table.RemoveColumns(#"Переименованные столбцы",{"Расход, руб"}),
#"Вставлено: объединенный столбец" = Table.AddColumn(#"Удаленные столбцы", "key_dir", each Text.Combine({[N кампании], "-", [N группы]}), type text),
#"Удаленные столбцы2" = Table.RemoveColumns(#"Вставлено: объединенный столбец",{"N кампании", "N группы"}),
#"Измененный тип1" = Table.TransformColumnTypes(#"Удаленные столбцы2",{{"Расходы, руб", type number}})
in
#"Измененный тип1"
annotation PBI_NavigationStepName = Навигация
annotation PBI_ResultType = Table