classic report and derived columns - oracle-apex

I have a classic report 2 columns are coming from the table and the 3rd column is a derived column.
I want to compute the values of the 3rd column based on the value of the 2nd column like if the 2nd column value is 1 then I want to put '-' in the 3rd column if it is >1 then in the 3rd column I want to put 'More than one dates'
And I want to have filters in the 3rd column header with the values that I put, I this case '-' and 'More than one dates'
And when I select the filters I want the report to be filtered accordingly.
I have a put a screen shot of the report.
Please can anyone let me know how to accomplish this.
Any help will be more than welcome
Apex 5.1 and Firefox
Snap Shot of the Report

Your SELECT-Statement should look something like this:
select ULA_ORDER_NUMBER,
COUNT,
CASE WHEN COUNT = 1 THEN '-' ELSE 'More than one dates' END as FILTER
from YOUR_TABLE
For the filter just "double click" on the COUNT column header.
This is what it looks like:
Hope this helps you.

Related

Is there a way to get people name in calculated column in MS LISTS?

I am working on a Leave Tracker in MS LISTS, where in the Calendar view I want the Proxy name to be displayed.
I have searched more than 100 Links and I couldn't the answer.
Do we have any workaround for it?
Thanks for the answer in advance.
According to my research, the “Person Or Group” column is not supported in the SharePoint Calculated column
SharePoint Calculated column supports the following types of columns:
Single line of text
Choice (menu to choose from) | Single Selection
Number (1, 1.0, 100)
Currency ($, ¥, €)
Date and Time
Yes/No (checkbox)
Calculated (calculation based on other columns)
Task Outcome
External Data
Content-Type Columns
We recommend that you can create a Single line of text column to fill in the Proxy Name.
Then, you can create a Calculated column which concatenates the Title, and Proxy Name(Single line of text) columns,
Modify the Calendar view and change the "Month View Title" column to your new Calculated column.

Power BI Query Editor - Inserting Rows to the Bottom of a Table

I have a table that looks like this in Power BI:
CourseID Course
1 Math
2 Cooking
3 English
4 Spanish
I want to insert a row at the bottom that looks like this:
-1 null
I looked at the Microsoft Documentation, but it's not very helpful. Any suggestions?
Figured out what I was doing wrong.
Let's say I wanted to insert a row, at top of a table, named Courses.
The M query would look like this
#Insert Row = Table.InsertRows(#PreviousStepName,0,{[CourseID=-1,Course=null]})
Was not able to get it working if the column name had a space in it, but for best practices, you shouldn't have columns with spaces in the name anyway.
Follow below steps to insert a row to the bottom of a table:
Step 1: Go to the edit query window. select the correct table.
Step 2: Go to the APPLIED STEPS window on the right-hand side. double click on Source.
Step 3: Add the data to each column and press ok.
Note that, this will only add a row to the end of the table.
The accepted answer above by OP works great if you want to insert a row at the top of the table, or if you know the index to insert at. In my case I want to append to the end, and the amount of rows is likely to change in future.
I saw the functions to reverse the rows, so you could reverse the rows, insert at 0, then reverse again, but I found another way:
#"Insert Row" = Table.Combine({#"Previous Step Name",
Table.FromRows(
{{null, "None", true, false}},
{"ID", "Name", "Deleted", "IsIntegration"}
)
})
Basically, you create a new table with Table.FromRows, then use Table.Combine to append it

Refer to slicer-filtered table in DAX calculated column

I'm beginning to think that what I'm looking for isn't actually possible.
I have two datasets - one of Titles and one of Keywords. Only one column from each is relevant to this query - Titles[Title] and Keywords[Keyword]. So pretty straightforward data. Titles has around 2 million rows, and Keywords will eventually have ~500-1000.
I would like to display a slicer of Keywords[Keyword] values, which will filter the Titles dataset where Titles[Title] contains one of the selected Keywords[Keyword] values.
I tried creating a DAX calculated column on Titles like below -
Matches = IF(SUMX(FILTER('Keywords','Keywords'[Keyword] <> ""),FIND(UPPER('Keywords'[Keyword]), UPPER(Titles[Title]),,0)) > 0,1, 0)
I then apply a report level filter for Matches >= 1. This works for all keyword values, but is not aware of the selection in the slicer.
I tried changing it to use ALLSELECTED('Keywords'[Keyword]) as the first argument passted to FILTER, but this doesn't seem to have any effect.
As a test, I created a Calculated Column and a Measure with the exact same DAX -
CONCATENATEX(VALUES(Keywords[Keyword]), Keywords[Keyword], ",")
This displays the slicer selection delimited by commas for the measure, but not for the column. Since I want to calculate this per row and filter the report based on this, a measure isn't suitable.
Is there any other way I can refer to the filtered Keywords[Keyword] in my calculated column? Or is there a way that a Measure could actually be used to achieve this? Or is there a completely different approach that I could try?

Power BI : How to count occurrence of value from source table?

I have my data source something like below.
I need to show output in the report as below.
I tried using the unpivot column and getting something like this, how to count the occurrence value of each Business value.
Plot following mesure against Value column (from your unpivot table):
Business Occurance = COUNTROWS('your unpivot table')
We have to remove the Attribute column as the next step to Unpivot. Then my table should be looks like this.
Now create a new table with following Dax function, let's say the current table as Business Data (Your Unpivot table)
Occurrence Table = DISTINCT('Business Data')
Now end result table should look like this,
You can make use of this table for your table visual in the report.
Note: You can add n-number of rows and column into your source table and this logic will do magic to get the correct result.
I have marked two places first marked place you have to add Value column then click second marked place one dropdown value is open click count menu

Add Hyperlink below the Card or table visual Conditionally in power bi

I have a Power-Bi Report where I need to show the hyperlink in the card or table conditionally. the report is having Account_id as slicer value.
If an account_id results more than 4 records in the visual, I need to add a extra row with text "More.." in it. Reference image is below.
Thanks in advance
I don't if it's possible to get exactly what you want, but here's my attempt. Power BI still isn't great if you need a lot of control over formatting.
First, create a ranking column:
Rank = RANKX(
FILTER(ALL(Table1),
Table1[account_id] = EARLIER(Table1[account_id])),
Table1[Partners], , ASC)
Next, a column that displays the top ones and "More..." for any possible 5th items.
Display = IF(Table1[Rank] > 5,
BLANK(),
IF(Table1[Rank] < 5,
Table1[Partners],
"More..."))
Finally, a column that contains the desired URL for the "More..." rows:
Link = IF(Table1[Display] = "More...", "http://www.URL.com", BLANK())
Here's what my sample data table looks like:
Then you can set up a table with the Display and Link column. Make sure to choose "Don't summarize" for the field and choose URL icon on under values formatting options to get the link icon instead of a URL. You'll probably also want to filter out blanks in your visual fitter settings.
For the right-hand table above I changed the column header texts to "Partners" and " " in the table Values box.