Solved

Calculating multiple durations

Posted on 2011-03-20
10
359 Views
Last Modified: 2012-05-11
I have a previous solution (Question) that needs some further fine tuning. Current data is sorted under room numbers and may have more than one transaction within a day or after registration. : Please see Image or Report data included. The issue I'm currently running into is if there is more than one transaction I only calculate the duration from the last transaction which would be less revenue than if I use the Total duration while someone is actually present.


 Example Transactions PARC-Report-.pdf PARC-Report-.rpt parc.txt
0
Comment
Question by:John-S Pretorius
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
10 Comments
 
LVL 101

Expert Comment

by:mlmcc
ID: 35186165
What duration do you want to calculate?

WHat constitutes the start and end of the duration cycle?

What about multiple entries and exits in a day?

Are you only counting time when the car was in the lot?

mlmcc
0
 

Author Comment

by:John-S Pretorius
ID: 35186256
I'm trying to calculate only the duration when the vehicle is parked inside the garage.

Single entries I'm not worried about, multiple entries causes wrong totals as currently I'm using the last transaction.

Typically if someone is parked for longer than a day I use midnight and end of day but if the user is parked from registration that becomes the starting point.

I'm really only interested in up to7 hrs as that would-be the max day rate that can be charged, I'm trying to be more accurate with the duration as should some only have a last entry of an hour I currently will calculating $2, which is wrong if he had multiple transactions see example.
0
 
LVL 101

Expert Comment

by:mlmcc
ID: 35190203
So an in at 9PM get 3 hour charge for the day since it didn't leave

WHen he leaves at 9AM he gets a 9hr charge on the next day. Any concern about overcharge since the total duration was over 7 hours?

In 3pm, out 6pm, in 10pm 5 hours

mlmcc
0
On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

 

Author Comment

by:John-S Pretorius
ID: 35190337
For single transaction I have it doing exactly that : in at 9pm will calculate his duration as 3Hrs parked until midnight and should he leave at 9am he was parked for 9 Hrs. (This is the easy part for single transactions) - I also have to look out for single day transaction that actually registered on the same day vs the previous day if it's on the same dat duration would be from registration but if it's from a previous day it its from midnight.

I am more interested in the total duration if the count (of that groups > 1) so if there was 5 transactions (IN, OUTIN, OUT...) up to 7 hours, after 7 Hrs I don't care because that will be the max rate. I am trying to be more accurate in the duration captured for users actually parked inside. for a day.

I am currently also working on another question exporting each days report to SQL so that I can then later create a accumilative report that will tell me the charges for each user for previous days is he was been parked on the prvious day.

Unfortuanatly I can only use RAW data / day and cannot get this previous day day from the original database due to 'something weird' which I'm not sure will be rectified hence the work-around.
0
 

Author Comment

by:John-S Pretorius
ID: 35449191
I still have no solution
0
 
LVL 101

Expert Comment

by:mlmcc
ID: 36242083
Are you still looking for a solution?

mlmcc
0
 

Accepted Solution

by:
John-S Pretorius earned 0 total points
ID: 36242095
Completed a solution by grouping differently,
0
 
LVL 101

Expert Comment

by:mlmcc
ID: 36275174
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Crystal Reports: 5 Tests for Top Performance It is complete, your masterpiece report.  Not only does it meet your customer’s expectations, it blows them out the water, all they want is beautifully summarised and displayed in a myriad of ways. …
Hot fix for .Net Crystal Reports 10.2.3600.0 to fix problems with sub reports running on 64 bit operating systems ISSUE: Reports which contain subreports fail with error "Missing Parameter Value" DEPLOYMENT SERVER OS: Windows 2008 with 64 bi…
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question