Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Calculation that nulls are in one field

Status
Not open for further replies.

thorny00

Programmer
Feb 20, 2003
122
US
Using CR 10.0
Have the following formula. The hmsend field can have nulls in it. How do I account for the nulls in the formula?

{tblBatchMaster.RecCnt}/datediff("s",{tblBatchLog.HMSStart},{tblBatchLog.HMSEnd})

Thanks in advance for you time and help, I really appreciate it!
 
Try:

if datediff("s",{tblBatchLog.HMSStart},{tblBatchLog.HMSEnd} = 0 then
0
else
{tblBatchMaster.RecCnt}/datediff("s",{tblBatchLog.HMSStart},{tblBatchLog.HMSEnd})

-k
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top