Nested If Statements

Nested If Statements

Having a problem creating a nested if statement.  This works:

if((Imported_BPD  >  -1),Imported_BPD,((Feet  *  12  +  Inches  +  Quarter  -  Previous_Production_Inches)  /  ((Date_Time - Previous_Date_Time)  /  (1000  *  3600  *  24))  *  Tank_Factor))

However, I am wanting to add another check to say if the formula is <0, then BPD = 0.  Here is what I have tried but can't get it to work. Formula Field  Both the argument should be same type for 'IF' task. Expecting 'IF' expression found 'BIGINT' expression


if
(

(Imported_BPD  >  -1),Imported_BPD, 

if(

((Feet  *  12  +  Inches  +  Quarter  -  Previous_Production_Inches)  /  ((Date_Time - Previous_Date_Time)  /  (1000  *  3600  *  24))  *  Tank_Factor) < Previous_Production_Inches, 0,  ((Feet  *  12  +  Inches  +  Quarter  -  Previous_Production_Inches)  /  ((Date_Time - Previous_Date_Time)  /  (1000  *  3600  *  24))  *  Tank_Factor)  
)
)


I've also tried to use another formula field (inches per day) but can't seem to get that to work either.

Thanks,
Chris

    Zoho Desk Resources

    • Desk Community Learning Series


    • Digest


    • Functions


    • Meetups


    • Kbase


    • Resources


    • Glossary


    • Desk Marketplace


    • MVP Corner


    • Word of the Day


      Zoho CRM Plus Resources

        Zoho Books Resources


          Zoho Subscriptions Resources

            Zoho Projects Resources


              Zoho Sprints Resources


                Zoho Orchestly Resources


                  Zoho Creator Resources


                    Zoho WorkDrive Resources



                      Zoho Campaigns Resources

                        Zoho CRM Resources

                        • CRM Community Learning Series

                          CRM Community Learning Series


                        • Tips

                          Tips

                        • Functions

                          Functions

                        • Meetups

                          Meetups

                        • Kbase

                          Kbase

                        • Resources

                          Resources

                        • Digest

                          Digest

                        • CRM Marketplace

                          CRM Marketplace

                        • MVP Corner

                          MVP Corner




                          Zoho Writer Writer

                          Get Started. Write Away!

                          Writer is a powerful online word processor, designed for collaborative work.

                            Zoho CRM コンテンツ




                              ご検討中の方