drop down list suggestions limited to particular values - spotfire

I have a list of group leaders and each group leader has his own team, when a group leader clicks on his name, it leads him to his employees, I wanna make a drop down list so he can select the employee he wants but i dont want the drop down list to show all the employees from all the teams, i only want it to show the employees of that particular group leader.
there is no data limiting possible so i wonder how it is possible to do it, or if it is even possible.
Thank you in advance.

Create a reference data table with one column - 'leader'.
Create a reference data table with two columns - 'leader' and 'employees'.
Create a Document Property ('ldr') based on distinct column values from the 1st data table - which will allow leaders to select their own name.
The value of 'ldr' will now be used to filter the data in the 2nd data table, by going to Data Canvas, adding a 'Filter' transformatopm and using a custom expression like this:
case when DocumentProperty('ldr') = '' then true
when DocumentProperty('ldr') != '' and DocumentProperty('ldr') = [leader] then true
else false end
So now your 2nd data table should have only the employees of the selected leader.
Create a new drop down Document Property ('emp') based on distinct values in the employee column of the 2nd data table.
These two document properties created in the previous steps are just filters which have the appropriate employee values but are not linked to any visualization yet.
So to link the filters to the visualizations, go to Visualization properties -> Data -> Limit Data using expression -> Use an expression like:
[employees] = DocumentProperty('emp')

Related

SSRS Cells auto-merge

I'm having trouble unmerging cells on the report.
3 Suppliers for the query
I have a SQL query that shows 3 instances of a supplier (left joined to contact) as shown below. However, when running the report for the query the 3 instance of the supplier is merged into one. This is not desirable in my case because when exporting the report to excel, I'd like to be able to sort columns based on other properties, however, this would not be possible due the the merging of the rows. How can I get results to show individually?
Cells are Merged on the report
Within the properties of each Row Group you can specify which columns to group on. You generally don't need a separate group for each field, but that's OK. In your last group, the one called "(Details)", if it is not grouped by anything, it will show one row per line of results from the query. So take a look at what it's grouped by. As long as the rows are in your dataset, the report will group or show them based on how you configure the grouping here. Grouping on nothing means it will show all rows.
Another tip is to align the end of your header textbox with the line of one of your columns. This will prevent it from creating an extra column in Excel for the "City" field.
Your report does not need all of those groupings - the SSRS grouping is not like SQL. You should only group when you want to aggregate data on that field. Normally you might have a company with its address in various fields in one group but you only need to group once on the Company Name or (preferably) ID - not on each field and not a separate group for each. You could then show details of various invoices in other columns that aren't grouped.
But since you want to display the company data on each row, you would not want ANY grouping on the company.
To fix your issues, remove all the groupings (but not the rows) and just leave the detail group (which doesn't have a Grouping).
You can check out MS Docs: Understanding Groups for a better explanation.

PowerBI: Comparing a filterd table against a variable string is returning an empty table

Please see the code below for a Power BI table in DAX:
TABLE1 =
VAR ParticipantOneParticipantId =
SELECTEDVALUE(
ParticipantOneDetails[ParticipantId]
)
RETURN
FILTER(
ParticipantOneMeetings,
ParticipantOneMeetings[ParticipantId] = ParticipantOneParticipantId
)
I am fetching a value for ParticipantId from a sliced table called ParticipantOneDetails and setting ParticipantOneParticipantId to it.
In the next step I am trying to filter the table ParticipantOneMeetings based on its column ParticipantId comparing it against ParticipantOneParticipantId.
The problem is that the resulting table is coming out empty even though I know that ParticipantOneParticipantId must have a value and the ParticipantOneMeetings table also has values. I verified by comparing against a hard-coded string.
Can you please point out what I am doing wrong? Is comparing this way not legal?
The problem lies in the process you are trying. A calculated/custom tables and columns are static. They always refresh when the data set is refreshed. They do not interact dynamically with the slicer value. So it is impossible to get data from a slicer dynamically for a Custom Table generation.
Now, your requirement of creating a new table based on slicer value is not completely clear to me. As what you are trying, is a simple filtered output of your table "ParticipantOneMeetings" after applying the Slicer. If you have relation between your 2 tables using column "ParticipantId", change in Slicer will automatically filter out values in ParticipantOneMeetings table. Why you wants to hold this same filtered values in a new Custom table is really a mater here to know for finding appropriate solution for you.
Turns out I needed to add the following measure to the table output:
MeetingsAttendedByBothParticipants =
countrows(
INTERSECT(
VALUES(ParticipantOneMeetings[Name]),
VALUES(ParticipantTwoMeetings[Name])
)
)
The above provides an intersection on output of two sliced meeting tables. This results in a list of meetings that both persons attend.

How to make a dynamic list from a multi variable table with boolean values?

Please help, very stumped with this one.
I've been provided with a matrix table as seen in image attached. I have a list of users, as well as the courses that they need to be enrolled in.
I'm trying to create a list that will repeat the usernames for every course that they're enrolled in (in column A, and then a list of the courses they are enrolled in (column B)
So far, I've been able to create such a list by creating a pivot table from this data, double clicking the grand total, and sorting the results, but this is a very manual process, and it needs to be replicated by others.
Is that possible?
Google Drive link: https://drive.google.com/file/d/1zXsWZCguia-SLaYAP-81kMX819879zzX/view?usp=sharing
This is just something to get you started:
Convert your data to an Excel table
Steps:
In Excel:
Select the data range (starting from row 3)
Press Ctrl + T
Select Data | Get data from table
Transform your data in Power Query
In Power Query:
Select the columns headers (from FirstName to User)
Right click them
Select UnPivot other columns

Data in Rows Instead of Columns

The default List layout uses column headers with columns of data beneath them. This will not work for my report. I need to create an employee profile report that will return about 75 fields (job title, location, tax status, payroll deductions, etc.). This is a report that I want to be able to print on a single page for each employee. Using the The default List layout extends the data out in columns beyond the limits of a printed page, even in landscape.
How can I get my report to display in rows instead of columns, so that the field headers go from the top of the page to the bottom, with the data to the right of the headers. Even this will not be long enough to fit on a single page (that is easily readable), so I will need a second list to the right of the first. Like this:
Name: data Company: data
Location: data Employee Number: data
Job Title: data Date Hired: data
Thanks!
You can use a Repeater Table object to do what you want. This should be available in your toolbox. You group on the value you want to repeat on, likely an employee identifier in your case, and section on that value. That will produce one table per unique identifier value. In the table itself you can configure the number of rows and columns to fit the layout you want to produce and you are free to drag and drop objects from the model or query into the cells as needed.

Pivot table using 2 data ranges

is it possible to have a single pivot table that combines 2 worksheets as the data?
For example, first data table will be made up of the following columns:
ID/Details/Category
The second data table will be made up of the following columns:
ID/Customer name
The reason why the 2 tables are not combined is because there may be many customer names to the same customer name.
I want a pivot table that will show me the following things:
1) Be able to sort by ID and see for each ID the details linked to that ID sorted by category
2) Be able to sort by customer name and see the details linked to that customer sort by category.
Thank you for your help.
Press Alt+D+P. Select multiple consolidation ranges, choose your two ranges of data, and you've got it.

Resources