Forum Discussion
QuickBaseCoachD
8 years agoQrew Captain
:)
Right, I missed that ...
If(
$isSunday,ToTimestamp(ToDate(WorkdayAdd(ToWorkDate(ToDate([Date Time]))),2),ToTimeOfDay("8 pm"))),
$isSaturday,ToTimestamp(ToDate(WorkdayAdd(ToWorkDate(ToDate([Date Time]))),3),ToTimeOfDay("8 pm"))),
$isFriday and $isFridayEightPM,ToTimestamp(ToDate(WorkdayAdd(ToWorkDate(ToDate([Date Time]))),4),ToTimeOfDay("8 pm")),
$isFriday and not $isFridayEightPM, ToTimestamp(ToDate(WorkdayAdd(ToWorkDate(ToDate([Date Time])),2)),ToTimeOfDay([Date Time])))
)
There may be unbalanced brackets. I did not try to reconcile the closing ))) at the end of each line.
Note that with Quick Base, unlike Excel, you do not need to next your IFs. You can just start with one IF( and then list all your tests and results below in sequence.
That last ) at the end by itself is the closing to the beginning ( of the IF.
Right, I missed that ...
If(
$isSunday,ToTimestamp(ToDate(WorkdayAdd(ToWorkDate(ToDate([Date Time]))),2),ToTimeOfDay("8 pm"))),
$isSaturday,ToTimestamp(ToDate(WorkdayAdd(ToWorkDate(ToDate([Date Time]))),3),ToTimeOfDay("8 pm"))),
$isFriday and $isFridayEightPM,ToTimestamp(ToDate(WorkdayAdd(ToWorkDate(ToDate([Date Time]))),4),ToTimeOfDay("8 pm")),
$isFriday and not $isFridayEightPM, ToTimestamp(ToDate(WorkdayAdd(ToWorkDate(ToDate([Date Time])),2)),ToTimeOfDay([Date Time])))
)
There may be unbalanced brackets. I did not try to reconcile the closing ))) at the end of each line.
Note that with Quick Base, unlike Excel, you do not need to next your IFs. You can just start with one IF( and then list all your tests and results below in sequence.
That last ) at the end by itself is the closing to the beginning ( of the IF.
QuickBaseCoachD
8 years agoQrew Captain
Here is an example of an IF with several tests. You will see that the IF is not nested.
https://login.quickbase.com/db/bcgahn76w?a=dr&r=bm&rl=cwe
https://login.quickbase.com/db/bcgahn76w?a=dr&r=bm&rl=cwe