Help with MCode to count occurrences in my grouped data

Guitarmageddon

Board Regular
Joined
Dec 22, 2014
Messages
161
Hello everyone,
Im thinking this is quite simple, and I can do it if I rig up various pivot tables etc in regular excel ranges, but I really want to accomplish this with Mcode

I am doing analysis of a list of almost 500 business reports from within a BI tool, checking for duplications, how many times reports have been run for their usefulness, etc.... One thing that I am trying to discover but cant quite get there, is out of the columns you see below, how to craft a new column that shows for all the given reports (below list is filtered of course), what reports reside ONLY within the [TEAM CONTENT DIRECTORY] for "User Folder".

So taking the below example, my conditional formula would do something like "count number of instances you see the report" = e.g. 2. If count=1 AND [TEAM CONTENT DIRECTORY]= "User Folder" , then "X", else null

So for the lines below, I would not get an X for the rows which that report is represented. However, if that report ONLY resided inside "User Folder", then I would expect to see an X or TRUE or whatever indicator we specify. Would greatly appreciate any pointers


1722445209036.png
 

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.
Would also add that a way I found to accomplish was to create another table where I manually filtered to those conditions, and then just did a left join against the original master table. But maybe a more elegant solution?
 
Upvote 0
Sounds like you need to do a groupby. It’s in the menu. You need to groupby folder and file name and add a count. You can then add the conditional column you describe (which is also in the menu)
 
Upvote 0

Forum statistics

Threads
1,223,879
Messages
6,175,145
Members
452,615
Latest member
bogeys2birdies

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top