powerquery

How to replace a column name in Power Query by a variable to filter rows?

眉间皱痕 提交于 2021-02-20 03:40:21
问题 In a query developed with Excel Power Query I would like to replace the table column name with a variable, when I filter rows of a list. Unfortunately, I either get an error message (e.g. Expression Error: Column xx of table was not found) or no row is remaining after filtering even if it should. In the example below the variable #"Filter" (= column name) is set to column "B" and used in the step #"Filter Rows" to filter the rows which contain a '1'. But the result is that no row is shown.

How do I properly use table.group in a PowerQuery query to dynamically summarize different rows and columns?

陌路散爱 提交于 2021-02-19 08:32:33
问题 I created a table in Excel 2016 where I put various names of columns, columns I wanted to summarize, names to set new column names to, etc. Essentially what I wanted to be a parameter table. I then created a function in the Power Query editor and passed the values in the aforementioned table into the function. At first it failed, but I found Power Query column name as parameter which showed me how to pass one of the column names to a parameter. On first glance the group function seemed to

Filter Power BI report based on current user

北城余情 提交于 2021-02-19 05:39:12
问题 We're currently developing a Power BI Dashboard (Office 365) for our company and would like to tailor the information on the dashboard based on the current user's preferences. Our company has multiple departments and sub-departments, so to display every department's figures to all users would be counter-productive. For example if Bob is in Sales for Europe - he'll only see European sales, while Sue will only see Sales for America. Is there a way PowerBI can identify the current user and then

Excel Power Query - Is it possible to connect to Azure Blob Storage with SAS authentication or Azure AD account

自古美人都是妖i 提交于 2021-02-16 20:32:14
问题 I am accessing a container from a Azure Blob Storage with Excel, we connect through "New Query" but only gives the option to access with the Account Key. After logging the permissions are saved in Data source setting with the Account Key. To access that Azure Blob Storage from VBA is enough with the function from Power Query AzureStorage.Blobs (https://docs.microsoft.com/en-us/powerquery-m/azurestorage-blobs). ¿Is It possible to do the same with SAS (Shared Access Signature) Token or Azure AD

Excel Power Query - Is it possible to connect to Azure Blob Storage with SAS authentication or Azure AD account

那年仲夏 提交于 2021-02-16 20:32:07
问题 I am accessing a container from a Azure Blob Storage with Excel, we connect through "New Query" but only gives the option to access with the Account Key. After logging the permissions are saved in Data source setting with the Account Key. To access that Azure Blob Storage from VBA is enough with the function from Power Query AzureStorage.Blobs (https://docs.microsoft.com/en-us/powerquery-m/azurestorage-blobs). ¿Is It possible to do the same with SAS (Shared Access Signature) Token or Azure AD

power query merge two tables based on the transaction date between two dates

不羁岁月 提交于 2021-02-15 07:37:54
问题 I'm trying to perform a join between two tables (1 - transaction table and 2 - employee ID and date range) using Power Query where the transaction date is between two dates. Transaction Table +-------+-----------------+--------+ | EmpID | TransactionDate | Amount | +-------+-----------------+--------+ | 123 | 5/5/2019 | 30 | | 345 | 2/23/2019 | 40 | | 456 | 4/3/2018 | 50 | +-------+-----------------+--------+ Employee ID +-------+-----------+-----------+ | EmpID | StartDate | EndDate | +-----

How to pull data from Toggl API with Power Query?

随声附和 提交于 2021-02-11 18:15:49
问题 First timer when it comes to connecting to API. I'm trying to pull data from Toggl using my API token but I can't get credentials working. I tried to replicate the method by Chris Webb (https://blog.crossjoin.co.uk/2014/03/26/working-with-web-services-in-power-query/) but I can't get it working. Here's my M code: let Source = Web.Contents( "https://toggl.com/reports/api/v2/details?workspace_id=xxxxx&client=xxxxxx6&billable=yes&user_agent=xxxxxxx", [ Query=[ #"filter"="", #"orderBy"=""],

How to pull data from Toggl API with Power Query?

送分小仙女□ 提交于 2021-02-11 18:11:00
问题 First timer when it comes to connecting to API. I'm trying to pull data from Toggl using my API token but I can't get credentials working. I tried to replicate the method by Chris Webb (https://blog.crossjoin.co.uk/2014/03/26/working-with-web-services-in-power-query/) but I can't get it working. Here's my M code: let Source = Web.Contents( "https://toggl.com/reports/api/v2/details?workspace_id=xxxxx&client=xxxxxx6&billable=yes&user_agent=xxxxxxx", [ Query=[ #"filter"="", #"orderBy"=""],

How to pull data from Toggl API with Power Query?

和自甴很熟 提交于 2021-02-11 18:10:27
问题 First timer when it comes to connecting to API. I'm trying to pull data from Toggl using my API token but I can't get credentials working. I tried to replicate the method by Chris Webb (https://blog.crossjoin.co.uk/2014/03/26/working-with-web-services-in-power-query/) but I can't get it working. Here's my M code: let Source = Web.Contents( "https://toggl.com/reports/api/v2/details?workspace_id=xxxxx&client=xxxxxx6&billable=yes&user_agent=xxxxxxx", [ Query=[ #"filter"="", #"orderBy"=""],

Powerquery, does string contain an item in a list

房东的猫 提交于 2021-02-11 16:11:28
问题 I would like to filter on whether multiple text columns ([Name], [GenericName], or [SimpleGenericName]) contains a substring from a list. The text is also mixed case so I need to do a Text.Lower([Column]) in there as well. I've tried the formula: = Table.SelectRows(#"Sorted Rows", each List.Contains(MED_NAME_LIST, Text.Lower([Name]))) However, this does not work as the Column [Name] does not exactly match those items in the list (e.g. it won't pick up "Methylprednisolone Tab" if the list