Tableau - How to have a measure to count success or failure - tableau-api

I am looking to find out how I can create a measure in Tableau that will tell me if a job has been successful or not.
For example I have an agent and I am trying to calculate the number of jobs he worked on and if the completed column has a value of 1 then he successfully completed this otherwise I count it as a failure.
So for this reason I created a calculated field that has the following:
IF [Completed]="Y" THEN 1 ELSE 0 END
I then created a new sheet with the number of records for that agent in columns and the measure(above) in rows to create a stacked chart.
The problem I have is that the incompleted tasks are not being counted therefore not reflecting correctly on the chart.
Being new to Tableau I am not sure how to resolve this and would appreciate some advice if possible.
Thanks in advance.

You dont have to create any calculated field to achieve this.
Tableau has a built in measure named 'Number Of Records' which has a value of '1' for each record. Assuming your data is this:
Than you can use it in the chart or table like this:

Related

SharePoint List calculated value

I am using SP lists to maintain users PTO and a Master list to forecast utilization hours based on their goals as follows. I am on SharePoint 2013, what calculated formulas can I use to get the Forecast hours in the Master list? Thanks much!
Included are sample PTO & Master List
MasterList
PTOList
I’m afraid that we can not achieve this with calculated column. We can not get look up value in calculated column formula. It is even more impossible for us to get the sum of all hours based on time and a specific person.
I recommend you to create an event receiver on PTO_List(item added) to achieve this.

Tableau Fixed Calculation Summing too much data

I have volume data for specific customers. The customer names come from salesforce and the volume comes from another table. When I add each in tableau, i get a nice table that seems to be working.
We can see that there are 19 values ~500 My ultimate goal is to sum these based upon filters.
A way i discovered that i can do that is to use the syntax
{ FIXED [Account Id]: count([Volume]) }
But when i do that,
I get
When I change my function to count([volume]) i get a count of all joined rows ~250k
My question is how do i make this respect indivudal entries in the database and not all the joined values? If there was a way to do the sum for distinct timestamps in another field this would also work? Any other advice would be helpful from you tableau experts.
Thanks!
I think i got it. In the table of the database that i was trying to calculate there were 20 rows that needed to be calculated. When the data was joined in SF, it duplicated the rows. The trick here was to do the sum of the max for each primary key
SUM({ FIXED [Pk], [Name1] : MAX([Volume]) })

tableau grant total not giving me correct out put from calculated field

as my previous question i was not able to give sample data I have updated another question which will help to solve this problem
I have a sample excel file
using above data I have created tableau calculated field called bonus
if ISNULL(SUM([active]))
then 0
ELSE
sum([Sale])*SUM([Per])
END
All my calculation is right however when I use Column grant total it coming wrong values.
How can I fix Grand total in tableau

Crystal report: Adding more column to the existed chart

I'm using Crystal Report 11.5.12.1838.
I wanted to add more column 'Total" for each month to the chart the blow:
Chart1
I've tried both Running Total field and the Cross-tab. but it's lead me to nowhere as it's not my expectation.
As Running total field, it's increase the quality by the time, not separate for each month.
As the Cross-tab, it's generated another chart, instead of adding to the existed one.
I'm completely new with this so there may have some trick that i haven't know.
Please help me on this.
High appreciate if any input.
Edit.....................................................................
Please take a look on the Running total of mine: Running Total Configuration I added the summary to the footer before. You can see it in the brown highlighted: Expected chart
As i wanted to add this total column to the chart, but when using Running Total time, it's increase continuously. And the matter is i didn't know how to add more column to the existed chart.
Thanks for your time,
Running total should work but if you are unable to use the running total... Post what have you took in Evaluate and Reset so that we can see if anythig wrong you have done.
You can follow one more appraoch which is very simple and gives you sum.
Group the report with month
Place the remaining data in details
Now take the summary in group footer by Right Click field --> insert summary --> take sum to group footer
Let me know if you face any issue

Crystal Report: Get Minimum Date

I have this concern using Crystal Report which I am not really familiar with. Here's my scenario:
I have an existing report to update, I need to add a column (ETA) which has a datetime value. It may return more than one rows per Item No, I need to get the minimum date only per Item No from the result rows.
I already tried some solution mentioned here http://scn.sap.com/thread/1952829 but found no luck.
I used a suppression formula for the Details section of the report, but haven't succeeded yet.
IF {TableName.DateField} = Minimum({TableName.DateField}) THEN FALSE ELSE TRUE
Any possible things you can suggest me to try? Thanks in advance for this :)
good to get this value from sqlserver side. you just create a function which return a single data (minimum date).
If you wish in crystal report side, it is something you make loop of hundred for a single row display. You can use running total field for this.
Select the field , select summary type and put into the detail section.
or you can create a formula with group name option like
Minimum({TableName.DateField})
http://scn.sap.com/thread/1952829
http://businessintelligence.ittoolbox.com/groups/technical-functional/businessobjects-crystal-l/unable-to-filter-based-on-the-first-date-in-list-of-dates-4912881
please check
Running total field gives options for Min, Max, etc. but not Sum
http://flylib.com/books/en/4.229.1.28/1/