Forum Discussion
Formula.Firewall message when I create a custom column.
- 6 years ago
Hello Anonymous
I've checked your file now more deeply. you have 2 possibilities
Switch off the Firewall (File-> Options -> Privacy settings)
or you combine all your code in one query like that
let SourceCen = Excel.Workbook(File.Contents("yourExcelfileCentral"), null, true), RemovedColumnscen = Table.RemoveColumns(SourceCen,{"Name", "Item", "Kind", "Hidden"}), ExpandedDataCen = Table.ExpandTableColumn(RemovedColumnscen, "Data", {"Column1", "Column3"}, {"Column1", "Column3"}), PromotedHeadersCen = Table.PromoteHeaders(ExpandedDataCen, [PromoteAllScalars=true]), FilteredRowsCen = Table.SelectRows(PromotedHeadersCen, each true), RemovedDuplicatesCen = Table.Distinct(FilteredRowsCen), SourceDail = Excel.Workbook(File.Contents("yourExcelfileDaily"), null, true), RemovedColumnsDail = Table.RemoveColumns(SourceDail,{"Name", "Item", "Kind", "Hidden"}), ExpandedDataDail = Table.ExpandTableColumn(RemovedColumnsDail, "Data", {"Column1", "Column3"}, {"Column1", "Column3"}), PromotedHeadersDail = Table.PromoteHeaders(ExpandedDataDail, [PromoteAllScalars=true]), New = Table.NestedJoin(PromotedHeadersDail, {"URL"}, RemovedDuplicatesCen, {"URL"}, "CENTRAL_BelfastHousesBUY", JoinKind.LeftAnti), #"Removed Columns1" = Table.RemoveColumns(New,{"CENTRAL_BelfastHousesBUY"}), Page = #"Removed Columns1"[Page], #"Removed Duplicates" = List.Distinct(Page), #"Removed Bottom Items" = List.RemoveLastN(#"Removed Duplicates",1), #"Converted to Table" = Table.FromList(#"Removed Bottom Items", Splitter.SplitByNothing(), null, null, ExtraValues.Error), #"Added Custom1" = Table.AddColumn(#"Converted to Table" , "Custom", each GetDataPage([Column1])) in #"Added Custom1"If this post helps or solves your problem, please mark it as solution (to help other users find useful content and to acknowledge the work of users that helped you)
Kudoes are nice too
Have fun
Jimmy
Same message Jimmy 😫. The thing is, page number is obtained by comparing both tables to check for new items (LeftAnti). Is there any other way to replicate that list and then add a custom column calling the function? The only one I can think of is exporting that list and bring it back withing a new table but I tried to do it thought a R script and it showed me the same message againðŸ˜. I am sure there should be another workaround. Many thanks for your help.
Regards
Hello Anonymous
I've checked your file now more deeply. you have 2 possibilities
Switch off the Firewall (File-> Options -> Privacy settings)
or you combine all your code in one query like that
let
SourceCen = Excel.Workbook(File.Contents("yourExcelfileCentral"), null, true),
RemovedColumnscen = Table.RemoveColumns(SourceCen,{"Name", "Item", "Kind", "Hidden"}),
ExpandedDataCen = Table.ExpandTableColumn(RemovedColumnscen, "Data", {"Column1", "Column3"}, {"Column1", "Column3"}),
PromotedHeadersCen = Table.PromoteHeaders(ExpandedDataCen, [PromoteAllScalars=true]),
FilteredRowsCen = Table.SelectRows(PromotedHeadersCen, each true),
RemovedDuplicatesCen = Table.Distinct(FilteredRowsCen),
SourceDail = Excel.Workbook(File.Contents("yourExcelfileDaily"), null, true),
RemovedColumnsDail = Table.RemoveColumns(SourceDail,{"Name", "Item", "Kind", "Hidden"}),
ExpandedDataDail = Table.ExpandTableColumn(RemovedColumnsDail, "Data", {"Column1", "Column3"}, {"Column1", "Column3"}),
PromotedHeadersDail = Table.PromoteHeaders(ExpandedDataDail, [PromoteAllScalars=true]),
New = Table.NestedJoin(PromotedHeadersDail, {"URL"}, RemovedDuplicatesCen, {"URL"}, "CENTRAL_BelfastHousesBUY", JoinKind.LeftAnti),
#"Removed Columns1" = Table.RemoveColumns(New,{"CENTRAL_BelfastHousesBUY"}),
Page = #"Removed Columns1"[Page],
#"Removed Duplicates" = List.Distinct(Page),
#"Removed Bottom Items" = List.RemoveLastN(#"Removed Duplicates",1),
#"Converted to Table" = Table.FromList(#"Removed Bottom Items", Splitter.SplitByNothing(), null, null, ExtraValues.Error),
#"Added Custom1" = Table.AddColumn(#"Converted to Table" , "Custom", each GetDataPage([Column1]))
in
#"Added Custom1"
If this post helps or solves your problem, please mark it as solution (to help other users find useful content and to acknowledge the work of users that helped you)
Kudoes are nice too
Have fun
Jimmy
- Anonymous6 years agoNot applicable
Jimmy you are the man. Thanks for your time, finally it worked perfectly.