Results 1 to 3 of 3

Power Query Grouping Column as list

Threaded View

Dicken Power Query Grouping Column... 05-16-2023, 11:56 AM
romperstomper Re: Power Query Grouping ... 05-17-2023, 03:40 AM
Dicken Re: Power Query Grouping ... 05-17-2023, 07:48 AM
  1. #1
    Forum Contributor
    Join Date
    08-03-2021
    Location
    London
    MS-Off Ver
    365
    Posts
    777

    Power Query Grouping Column as list

    Hi,
    I've managed to get the result I wanted but aren't sure how ;
    I've attached workbook showing all examples;

    I've grouped some data all rows and then within that wanted to do a running total using list sum with list firstN and index.

    this is what I've got,

    Table.Group(  Source, { "Item"} , {{"All", each
    
              Table.AddColumn ( 
    
                       Table.AddIndexColumn( _ , "Index", 1,1,Int64.Type),
    
                                       "new", (A)=>   List.Sum( List.FirstN(  [Units] ,  A [Index]     )) ) }} )
    What I would like some help in understanding is if you just put in [Units]

     Table.AddIndexColumn( _ , "Index", 1,1,Int64.Type), "new", (A)=> [Units] ) }} )
    you get a list but if you do the same with index you get an
    error? it has to be prefixed with the function ; can someone explain or point me in the direction of information other than MS docs.
    also I realise this is probably not the best way of approaching this.


    Richard.
    Attached Files Attached Files

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Power Query Grouping undos sort
    By KerahJoy in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 12-18-2022, 09:12 AM
  2. [SOLVED] Power Query Grouping Lists displays
    By JyothiGrace in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 12-17-2022, 08:35 AM
  3. Grouping Power Query Column
    By nick3516 in forum Excel General
    Replies: 5
    Last Post: 11-06-2022, 01:30 PM
  4. [SOLVED] Excel Power Query Grouping list
    By Dicken in forum Office 365
    Replies: 9
    Last Post: 08-15-2022, 08:21 AM
  5. [SOLVED] Power Query extract values from list column with nulls
    By Imbizile in forum Excel General
    Replies: 4
    Last Post: 02-04-2021, 10:00 AM
  6. Data grouping in Power Query
    By hudson andrew in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-12-2020, 10:44 AM
  7. Help with grouping in power query
    By stephme55 in forum Excel General
    Replies: 1
    Last Post: 07-26-2016, 03:09 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1