+ Reply to Thread
Results 1 to 17 of 17

Parking Fees

  1. #1
    Registered User
    Join Date
    11-21-2021
    Location
    Melbourne, Australia
    MS-Off Ver
    MS Office 365
    Posts
    8

    Parking Fees

    Hi,

    I need help in calculating peak and off-peak rates.
    The parking may involve parking fees outside of the peak like it becomes night rate or weekend rate.

    Not sure how to go about it.

    Thanks in advance.
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Parking Fees

    Try in G2:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    And in H2:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Good luck!

    EDIT: No need to multiply value by duration, as your values are pre-calculated.
    Last edited by Estevaoba; 11-21-2021 at 09:53 PM.

  3. #3
    Registered User
    Join Date
    11-21-2021
    Location
    Melbourne, Australia
    MS-Off Ver
    MS Office 365
    Posts
    8

    Re: Parking Fees

    Thanks but I forgot to put a sample of mixed times. After 5pm and following day exit and it's a weekend it becomes off peak.

  4. #4
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Parking Fees

    It is a little tricky when it comes to overlapping duration.
    I can restrict calculation for weekday AND from 7:00 thu 17:00 only, with this formula:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Next step, we'll have to play with those times left before and after the peak rate period.
    I'll get back to this as soon as I can, and hopefully this will help you get started.

  5. #5
    Registered User
    Join Date
    11-21-2021
    Location
    Melbourne, Australia
    MS-Off Ver
    MS Office 365
    Posts
    8

    Re: Parking Fees

    Appreciate your help.

  6. #6
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Parking Fees

    Hello, spiralcookie.

    To the formula in post #4, I added a second IF(AND and now it looks like this:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    As I said before, the first IF(AND will restrict count to weekdays and from 7:00 thru 17:00.
    The second IF(AND will verify entry time after 17:00 and if entry day is different from exit day and, if True, it will subtract entry time from 17:00 and will return the equivalent amount for that difference only.

    I also elaborated the off peak formula so it will on weekdays verify entry after 17:00 OR exit not on the same day.
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    For the sake of simplifying those formulas, I took the liberty of reorganizing the hours table in your Rates tab.
    Also, I added start and end time of night period, so you don't have to hard code them in the formula.

    Please run some test and let us know how it goes.
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    11-21-2021
    Location
    Melbourne, Australia
    MS-Off Ver
    MS Office 365
    Posts
    8

    Re: Parking Fees

    Thank you!

  8. #8
    Registered User
    Join Date
    11-21-2021
    Location
    Melbourne, Australia
    MS-Off Ver
    MS Office 365
    Posts
    8

    Re: Parking Fees

    I tried entering before and on 7am, no cost for both rate is appearing.
    15/10/2021 5:00 15/10/2021 10:00
    15/10/2021 7:00 16/10/2021 10:00

  9. #9
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Parking Fees

    I added a new IF(AND to those formulas to contemplate entry before 7:00.

    As for the fault in entry time at 7am, it is due to a decimal difference that for some reason the Excel finds, starting on the twelfth decimal between these two values:
    0.291666666664241 = MOD(day & 7:00,1)
    0.291666666666667 = 7/24 = 7:00:00
    So, to get around that issue, I now entered 0.291666666664241 in cell C14 in your Rates tab and formatted as time.
    I did the same in cell D14, just in case.
    Attached Files Attached Files

  10. #10
    Registered User
    Join Date
    11-21-2021
    Location
    Melbourne, Australia
    MS-Off Ver
    MS Office 365
    Posts
    8

    Re: Parking Fees

    Looks good, thanks for your help on this

  11. #11
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Parking Fees

    You're welcome. Glad to help.
    Thanks for the feedback and for the reputation added.
    Have a blessed day.

  12. #12
    Forum Expert
    Join Date
    02-10-2019
    Location
    Georgia, USA
    MS-Off Ver
    Office 365
    Posts
    2,849

    Re: Parking Fees

    Just for the heck of it, here's another option for the Peak Rate - I think this gives the correct answer:

    =IFERROR(XLOOKUP(IF([@Day]="Weekend",0,MAX((MIN(EDATE(A2,0)+17/24,B2)-MAX(EDATE(A2,0)+7/24,A2))*24,0)),mins,club,,-1),0)

    The change that you need to make is to change cell A2 on the "Rates" table to .01

  13. #13
    Registered User
    Join Date
    11-21-2021
    Location
    Melbourne, Australia
    MS-Off Ver
    MS Office 365
    Posts
    8

    Re: Parking Fees

    Just one more, when I tried to enter this times 26/11/2021 16:00 - 26/11/2021 18:00 no rates happen. TIA

  14. #14
    Forum Expert
    Join Date
    02-10-2019
    Location
    Georgia, USA
    MS-Off Ver
    Office 365
    Posts
    2,849

    Re: Parking Fees

    I assume you're referring to the formula from Estevaoba. Using my formula I get $7.50

  15. #15
    Registered User
    Join Date
    11-21-2021
    Location
    Melbourne, Australia
    MS-Off Ver
    MS Office 365
    Posts
    8

    Re: Parking Fees

    Hi Greg, Yes for Este, when I tried your formula it shows an amount on weekend and night rate which should be zero.

  16. #16
    Forum Expert
    Join Date
    02-10-2019
    Location
    Georgia, USA
    MS-Off Ver
    Office 365
    Posts
    2,849

    Re: Parking Fees

    The formula I gave was only for Peak rate (as stated in Post #12)

  17. #17
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Parking Fees

    Hello, spiralcookie.
    I have added an OR(AND to the second IF(AND so as to contemplate this scenario that was missing.
    Please give it a try.
    Formula: copy to clipboard
    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 2
    Last Post: 10-08-2021, 01:31 AM
  2. Rotating Parking List
    By Adamba in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 05-10-2018, 06:17 AM
  3. Counting Occupancy of Parking Garage
    By tycush7 in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 12-07-2016, 12:46 AM
  4. [SOLVED] Parking Schedule
    By warmanj in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 07-28-2016, 04:42 PM
  5. Car Parking Schedule...
    By it02s28 in forum Excel General
    Replies: 1
    Last Post: 06-12-2015, 08:53 PM
  6. Calculating parking fees, commission, etc
    By dragomirage9 in forum Excel General
    Replies: 3
    Last Post: 07-17-2012, 03:29 AM
  7. Replies: 6
    Last Post: 06-08-2012, 11:28 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1