Compare column values of different rows Spotfire - spotfire

I want to compare row value of a column with different rows of one other column in Spotfire.
Requirement is whenever Issue ID is on Hold, its childIds also need to be on hold. Seems to be a quick fix however I am stuck around this
Please refer the screenshot
Thanks in Advance!!

If you go to the Add Data Tables section, and select the name of the original data table in the section titled "From Current Analysis", you can add a second Data Table based off the original data.
Then go to Edit, Data Table Properties, and go to the Column Matches tab -- delete the current column matches (Presumably it matched "Issue ID" to "Issue ID" etc), and then add a new Column Match where your original table has "Issue ID" selected, and the other has "Parent ID" selected.
At this point, you can make a cross table based off of the original table, where Issue ID and Parent ID are along the Vertical Axis. In your aggregate, add the following code (substituting the name of your second table where it says "Parent"):
If(Max([Status]) is null, Max([Parent].[Status]), Max([Status]))

Related

How Can I transform very ugly looking data into a usable datatable using Power Query?

The data I am using is split into 3 sheets (STORE1, STORE2, STORE3 --- not very ideal) and is not formatted in table either.
I'm looking for a way in Power Query to create one column containing all months out of multiple columns containing sales per each month per product (If it isn't clear, screens will probably be helpful)
Basically transforming this :
Initial Sheets
into this :
Final Sheet
The "products" are linked to "type" via another table, and I would also like to have "store number" in the new table format as a header instead of having different sheets
As of now, I haven't found a way to do it.
Thanks already for the help,
Unpivot is the command you ar looking for.
Make a query for each sheet, the only operation you have to do is to add a custom column (Add column -> custom column, in the formula write just 1 for the query of store 1, 2 for the query of store 2, etc. then rename the new column to "store number"
append the three queries
select all the columns except the one from january to december and
click on Transform -> drop down menu under unpivot -> unpivot other
columns
I am not sure what you mean when you say that the "products" are linked to "type" via another table but if you mean that you have a
look up table where you have a column that matches "products" and
another where you have the "type" column, then you can merge your
query, I would suggest you make sure you don't have any duplicate in
you look up table.

Counting the frequency of unique entries in an excel column

I run a customer service department (I'm new to this so need to learn quickly) and I'm trying to get some analytics on our customer service requests. I have a table in excel documenting every individual service request and I would like a graph showing the total number of requests per customer.
I could write this manually (see below) but I would like it to automatically update as more service requests are entered.
I have tried looking for answers to this but can't find any that update automatically or that don't require a table elsewhere to be manually updated with each new customer. We often get new customers and I dont want to have to go back to this every time to update a reference table or customer list.
Surely there must be a way in excel to "Count all entries of each occurrence of a name in a column" in some kind of smart way?
I would really appreciate help with this!
Thanks in advance!
If you have 365 you could take advantage of spilled ranges.
On your second image put =UNIQUE(Table1[Customer]) in cell B3.
Put =COUNTIF(Table1[Customer],B3#) in cell C3 - this formula will
spill to all your unique customers.
Create two names ranges:
One called XAxis which references =Sheet1!$B$3#
One called ChartValues which references =Sheet1!$C$3#
Create your chart:
Set series value to =Sheet1!ChartValues
Set axis to =Sheet1!XAxis
Change Sheet1 to whatever your sheet is called remembering to wrap with ' if it has a space in the name.
Better to use pivot tables.
If below is your data,
Go to Insert > PivotTable
A popup will show like below
Specify the Table/Range
Specify also the Location (anywhere in the Existing Worksheet)
The view below will be displayed
Click the Customer checkbox and also drag the Customer field to fill the VALUES box as shown in the image below
You desired table will be displayed as below
Please vote up if okay.
Thank you everyone for your suggestions. I found a solution from multiple answers and comments.
I ended up going to my original table that I am using to create new service records. I added a column called "1" and just entered the number 1 in that column, for every row. I then "Hid" this column in the usual fashion.
I then created a pivot table from this table and selected to display columns "Customer" and "1" and used these columns to produce a bar graph. Here is the result (With the column "1" unhidden):
tl;dr:
Excel is unable to do this in any smart way, create a column in the original table contianing the number 1 so when a pivot table is made, it will auto sum the 1's for entries from the same customer. Create a plot from this.
It disgusts me . . . but it works.

Restructuring data in excel

I am trying to condense data in a specific way. I want any occurrences of the number 1 in each column to show up as 1 (regardless of how many times it occurs) with the corresponding site, in the corresponding column. Some sites occur multiple times in the original data, and I want to make it so that only one of each unique site shows up in the resulting data table with a 1 for the corresponding column if there any 1's in the column from the original data.
I would think it would be a vlookup function, but I have tried many different things and I am really stuck on this.
Image of original data and what I am trying to do:
Thank you
This assumes that your data set only contains 1 or blank and this approach uses a Pivot Table with MAX function. Below are details in case anyone doesn't know Pivot Tables.
Select a cell in your data and insert Pivot Table. Note, I added a title for column A, as you need that in the Pivot Table.
Click in the created Pivot Table and the PivotTable Fields dialog should pop up. If not, right click in Pivot Table and select Show Field List.
Drag the Field names (Code, a, b,& c) down to the appropriate blocks below. (Values under Columns will be created for you.)
Click on the drop down arrow next to each field name and select Max. That will rename it to "Max of ...". If that bothers you, then you can type the name you want into the Custom Name field. Note, it will not let you type the same name as the field name, eg a, but it will work if you put a space in front of it.
Given that the Pivot Table would be a lot of work for a large number of columns, here is a formula based approach. Put this formula in cell G2, then drag it down and across to fill your new table.
Note, you will have to populate all codes that you have in column F. And if any new codes are added later you will have to keep this updated. One of the advantages of a Pivot Table is that it will do this for you.
I know that you won't be putting this in these cells, so adjust accordingly. In fact, I would recommend this be in another sheet.
=IF(COUNTIFS($A:$A,$F2,B:B,1)>0,1,0)
COUNTIFS($A:$A,$F2,B:B,1)
This will count each occurrence when the value in column A matches your code $F2 AND the value in column B equals 1.
If that count is >0, then you know that at least one match was found and the IF will return 1, otherwise 0.

Update column in Excel spreadsheet on change of another column

I am creating an excel spreadsheet and I just want to know whether is it possible to update one column on selection of an item in another column.
ex: I have a list Country in A column and list of States in B column. can you please let me know when I select a Country in A only those states belongs to A Should be listed in B.
Can anyone advice me how to do this ?
If I get your problem exactly, what you need is a simple filter.
Select your table and put a filter (under Home tab, Sort & Filter).
Check the country you want to see the states of (click the little grey box with black arrow for the A column).
After that, only those states that belong to the country you selected should be visible.
Now, if the state is wrong, it means your original data is wrong.

getting powerpivot to setup a lookup table for month names

I have a MySQL DB and I fetch data from there via PowerPivot into a table.
Then I created a PivotTable from this table data.
Now the column month holds the month of the record as an index from 1 to 12. This doesn't look pleasing to the eye, hence I would like to replace the index with its respective month name.
Like "March" for 3.
Here comes the concept of the lookupt table into play. So I set up a lookup table for the month names in the sheet "Lookup-Tables".
I clicked the "create related table" button ...
... and next thing I see is the very month table in the PowerPivot window. The respective sheet I called "month names".
what is missing is the link of course:
As you can see I established a link between the original data table's column "month" with the lookup table's column "index".
but no matter if I refresh or even create a new PivotTable ... month still shows the index instead of the month name.
when I go back into the PivotTable I can select the lookup table's colum "index" which leads to a yellow message stating that "maybe the relationships should be freshly established". I click "do so" and next I see is a message that says that no relationship could be established!?
I don't get it?
My goal is pretty common sense and straight forward I think. If you have a different solution from using lookup tables ... maybe using DAX (which I don't know much about yet) ... that would be great.
Try this. Unselect the two red checkboxes highlighted below and select the green checkbox. Let me know if this solves your problem

Resources