TS_ACT_VALUE Calculation in Project Server - project-server

I am trying to use c# to create timesheet entries in Project Server and running across a problem with saving the number of hours for the timesheet line on a certain day.
If I look at the dataset, there is a property for TS_ACT_VALUE. If I use 1 hour it shows 60000. Does anyone know what the calculation is to get that value, or another method of saving the number of hours worked on a timesheet line item?

John,
Per the documentation at http://msdn.microsoft.com/en-us/library/websvctimesheet.timesheetdataset.actualsrow.ts_act_value.aspx the TS_ACT_VALUE column "represents the actual cost recorded for this timesheet line item."

I am aware of the actual definition of the column but was more interested in how they get the calculation for it. when i look at sample data the column is divisible by 1000

it simply because the time is reprensented in milisecond... simply multiply your value in a hour by 60000

Related

Trying to come up with a formula that would return different greetings given per cell based on a list of greetings

I have created a daily journal in Spreadsheets where each day has it's own section. In each section, I created a questionaire that asks the user how they are doing in that day. I would like to add on top of that questionaire a different greeting per day, so I wrote a list with 30 variations in each cell (for example: "hello", "good morning", "buenos dias", "bon jour"...).
Where the different greetings will show up
list of greetings
I tried to use the rand() formula to select different greetings but since that formula is volatile and updates every time I make a change, it wont work for me.
As a solution, Each daily section starts with a cell countaining the date, so I thought that since each day would have a different greeting, I could use the number value of each date to drive the selection (for example: 05/05/2022 is the number value 44686, the next day is 44687).
I thought about using the Index formula but it requires that I use a number from 1 to 30 to retrieve one of those 30 greetings. I think that even if I were to somehow transform the date into a number from 1 to 30, perhaps in a few days, the value would end up being bigger than 30.
Anyway, I appreciate any help!
Gabriel

How to show missing dates on PowerBI Clustered Column Chart

I have a data set which has incidents resolved w.r.t date. I would like to look at the trends of number of incidents resolved over the past 45 days only on a Clustered column chart.
I couldn't see entries for specific dates (because the number of incidents resolved was zero on that day). How do I include those dates as well showing the number to be zero?
I tried the following:
1) Enabling "Show items with no data" - While this working fine, it is removing the last 45 days filter and is showing me unnecessary trends. The last 45 days filter is set on a page level and report level filter as well.
2) Creating a new measure to replace null values with 0 when the count of incidents resolved on a particular day is 0 - It again removed last 45 days filter.
Someone please let me know what I can do to get the required trends over last 45 days.
Thanks
This can be late reply, but I hope it may be useful for future users. As I suggested in a comment, you can try using measure for achieving this.
I have designed the following table with sample data.
INCIDENT_RECORD Table:
Created Measure:
Total Incident = IF(SUM(INCIDENT_RECORD[Resolved Incident])=BLANK(),0,SUM(INCIDENT_RECORD[Resolved Incident]))
Now I have designed Clustered Column Chart with & without Measure to show difference for you.
Clustered Column Chart with/without Measure:
First graph is showing label as 0 (Zero) which doesn't have any value
for that date.
Second graph is not showing data for Jan-03 in your case.
Feel free to ask your doubts/clarifications in the comment section.
First, make sure the column on your x-axis is a date data type. Then go to the Format tab for the visual and under the X-Axis options, set the Type to Continuous (rather than Categorical).

Finding Difference from Previous Day Volume to Next Day Volume

I have been struggling to find the new incoming volume per day.
I have categories as : - total ticket, Resolved, closed and Daily left.
So the calc is everyday resolved and closed are moved from the queue and
'daily left = Total Ticket- (Pending + Closed)'
Now there is some carry forward everyday hence the total ticket for the next day includes some volume i.e. Daily left of previous day.
I am not able to figure out how to show that number, I have tried using previous value but it is not helping. Please suggest. Attaching a print screen of the data.
For 3rd the # of records are 33 however there is 1 carry forward from previous
day hence the Fresh Vol should be 32. I have used the formula to calc but it is
not giving correct result
sum([Number of Records]) - (PREVIOUS_VALUE([Daily Left Volume]))
This is taking the left over of current day and not previous day.
I am also using look Up function but that also does not show the current output.
The output from tableau after using the lookup function is below attached as well
I am new to this community and dont have enought reputation to comment :P. So writing few possible solutions here:
1) Make sure the data is sorted by date and is unique on date level. If it is not then Previous or lookup might not work
2) Another solution will be take running_sum of every field and then apply the operations. This should give right answer
3) If this does not will it possible to change the way you import the data?
a) Simply create another filed as Date_past = Date-1 in your raw data.
b) Duplicate your data.
c) join the two data sets on Date = Date_past
d) Now you have all the data of today's date and last day in one field and you can perform operations as you need

KDB+/Q query too heavy to handle

I want to grab data from a KDB data base for a list of roughly 200 days within the last two years. The 200 days are in no particular pattern.
I only need the data from 09:29:00.000 to 09:31:00.000 everyday.
My first approach was to query all of the last two years data that have time stamp between 09:29:00.000 and 09:31:00.000, because I didn't see a way to just query the particular 200 days that I need.
However this proved to be too much for my server to handle.
Then I tried to summarize the 2 minute data for each date into an average and just print out the average, so now I will only have 200 rows of data as output. But somehow this still turns out to be too much. I'm not sure if this is because I'm not selecting the data correctly.
My other suspicion is that the query is garbing all the data first then averaging each date, which means averaging is not making it easier to handle.
Here's the code that I have:
select maxPriceB:max(price), minPriceB:min(price), avgPriceB:avg(price), avgSizeB:avg(qty) by date from dms where date within(2015.01.01, 2016.06,10), time within(09:29:00.000, 09:31:00.000), sym = `ZF6
poms is the table that the data is in
ZFU6 is the symbol that im looking for
I tried adding the key word distinct after select.
I want to know if there's anyway to break up the query, or make the query lighter for the server to handle.
Thank you!
If you use 32-bit kdb+ and get infamous 'wsfull error then you may try processing one day at a time like this:
raze{select maxPriceB:max(price), minPriceB:min(price), avgPriceB:avg(price), avgSizeB:avg(qty)
from dms where date=x,sym=`ZF6,time within 09:29:00.000 09:31:00.000}each 2015.01.01+1+til 2016.06.10-2015.01.01

Tableau Future and Current References

Tough problem I am working on here.
I have a table of CustomerIDs and CallDates. I want to measure whether there is a 'repeat call' within a certain period of time (up to 30 days).
I plan on creating a parameter called RepeatTime which is a range from 0 - 30 days, so the user can slide a scale to see the number/percentage of total repeats.
In Excel, I have this working. I sort CustomerID in order and then sort CallDate from earliest to latest. I then have formulas like:
=IF(AND(CurrentCustomerID = FutureCustomerID, FutureCallDate - CurrentCallDate <= RepeatTime), 1,0)
CurrentCustomerID = the current row, and the FutureCustomerID = the following row (so it is saying if the customer ID is the same).
FutureCallDate = the following row and the CurrentCallDate = the current row. It is subtracting the future call time from the first call time to measure the time in between.
The goal is to be able to see, dynamically, how many customers called in for a specific reason within maybe 4 hours or 1 day or 5 days, etc. All of the way up until 30 days (this is our actual metric but it is good to see the calls which are repeats within a shorter time frame so we can investigate).
I had a similar problem, see here for detailed version Array calculation in Tableau, maxif routine
In your case, that is basically the same thing as mine, so you could apply that solution, but I find it easier to understand the one I'm about to give, I would do:
1) Create a calculated field called RepeatTime:
DATEDIFF('day',MAX(CallDates),LOOKUP(MAX(CallDates),-1))
This will calculated how many days have passed since the last call to the current. You can add a IFNULL not to get Null values for the first entry.
2) Drag CustomersID, CallDates and RepeatTime to the worksheet (can be on the marks tab, don't need to be on rows or column).
3) Configure the table calculation of RepeatTIme, Compute using Advanced..., partitioning CustomersID, Adressing CallDates
Also Sort by Field CallDates, Maximum, Ascending.
This will guarantee the table calculation works properly
4) Now you have a base that you can use for what you need. You can either export it to csv or mdb and connect to it.
The best approach, actually, is to have this RepeatTime field calculated outside Tableau, on your database, so it's already there when you connect to it. But this is a way to use Tableau to do the calculation for you.
Unfortunately there's no direct way to do this directly with your database.