# Thread: Excel Formula (2003)

1. ## Excel Formula (2003)

Hi,

I have a very complex worksheet with the a variation of formula's that are used thousands of times over.

Would it be possible to simplify the following three formulas into one?

In Q104 =IF(P104="","",COUNTIF(X_DR_1,P104)) - How many debits do I have identical to P104
In R104 =IF(P104="","",COUNTIF(X_CR_1,P104)) - How many credits do I have identical to P104
In S104 =IF(P104="","",IF(R104/Q104=1,"MATCH","NO MATCH")) - Do I have the same number of debits and credits

Any suggestions greatfully received!!

Thanks

Nath

2. ## Re: Excel Formula (2003)

Assuming you're only interested in whether they match:
=IF(P104="","",IF(COUNTIF(X_CR_1,P104)=COUNTIF(X_D R_1,P104),"MATCH","NO MATCH"))
should do it.

3. ## Re: Excel Formula (2003)

Hans, I cannot thank you enough!!! That should speed the worksheet up a lot!!!

Many Thanks
Nath

P.S, nearly brakfast time, diamond shreddies here I come..... :-)

4. ## Re: Excel Formula (2003)

Er, it was Rory who answered your question!

5. ## Re: Excel Formula (2003)

LOL, sorry, am in sleep mode!!

Cheers Rory!!!!

6. ## Re: Excel Formula (2003)

Glad to help.
Regards,
Hans. Er, no wait, Rory. <img src=/S/grin.gif border=0 alt=grin width=15 height=15>

#### Posting Permissions

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