combining two Excel formulas?

1. combining two Excel formulas?

Hi,

I have two formulas which both work individually but I need to combine them together into one long formula.

A) =COUNTIFS(K:K, "R",L:L, "P") ..... makes 93

b) =SUMPRODUCT((D8:D10000<>"")/COUNTIF(D8:D10000,D8:D10000&"")) ........... makes 136

If I was to use the filters to get the result I want there is 7 unique references in D which have a R in K and a P in L.

When I try to combine formula A with B i get 229 not 7.

2. Re: combining two Excel formulas?

Hello Neilv, welcome to the forum can you please upload a sample book

3. Re: combining two Excel formulas?

I have uploaded a smaller example

a count of all the R's and P's and a count of the unique instances of the CR number. I need to make this one formula which i think the result would be 3

4. Re: combining two Excel formulas?

Hello Neilv Count of all R's is 7 and All P's is 12 and Unique values in your uploaded sheet is 11 then how can it results in 3

5. Re: combining two Excel formulas?

Sorry i mean it must have and R and a P which brings it down to 4 rows, out of the 4 rows there is only 3 unique values in CR/INFRA number

6. Re: combining two Excel formulas?

Are you looking for something like this

7. Re: combining two Excel formulas?

You're amazing, that worked a treat!

Last thing i need to do now is expand on what you've done with one more condition to say and column Q is blank

So count all the unique references where they have both an R and a P and there is an issue

Sorry to be a pain

Like This !!

9. Re: combining two Excel formulas?

I cant thank you enough, thats worked perfectly!

10. Re: combining two Excel formulas?

Thanks you Neliv for reverting back !

11. Re: combining two Excel formulas?

i wish i could send you the whole sheet but its too big. In copying your formula over i have mad a mistake somewhere. Do you have any idea why its counting blanks in the CR collounm, also some refs are being counted twice? i'll try to give an example. Its the two boxes in Red im trying to calculate the first is all the R's and P's but only one of each number (not including blanks) the second is out of the ones counted which of these have issues.

When its right i think it should be 7 and 6

12. Re: combining two Excel formulas?

Hello Neilv In T8 copy and paste below and drag down
=IF(ISTEXT((\$S8)),IF(COUNTIF(\$S\$8:S8,S8)<>1,0,COUNTIF(\$S\$8:S8,S8)),"")
and in V8 copy and paste below and drag down
IF(ISTEXT((U8)),IF(COUNTIF(\$U\$8:U8,U8)<>1,0,COUNTIF(\$U\$8:U8,U8)),"")

13. Re: combining two Excel formulas?

Hello Neilv In T8 copy and paste below and drag down
=IF(ISTEXT((\$S8)),IF(COUNTIF(\$S\$8:S8,S8)<>1,0,COUNTIF(\$S\$8:S8,S8)),"")
and in V8 copy and paste below and drag down
IF(ISTEXT((U8)),IF(COUNTIF(\$U\$8:U8,U8)<>1,0,COUNTIF(\$U\$8:U8,U8)),"")

There are some leading and trailing space in your CR Numbers. To remove that spaces select Y8 and copy paste =Trim(D8) and Drag down once you have covered all value i.e. Till D42.Then select Y8:Y42 copy this and select d8, instead of paste,here do paste special, select values option only.That will do

14. Re: combining two Excel formulas?

Find attached file , I have adjusted the formulas.

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

Posting Permissions

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

X vBulletin 4.1.8 Debug Information

• Page Generation 0.08100 seconds
• Memory Usage 9,249KB
• Queries Executed 16 (?)
Template Usage (34):
• (1)footer
• (1)forumrules
• (1)gobutton
• (14)memberaction_dropdown
• (1)navbar
• (4)navbar_noticebit
• (6)option
• (6)postbit_attachment
• (14)postbit_legacy
• (14)postbit_onlinestatus
• (14)postbit_wrapper
• (1)spacer_close
• (1)spacer_open
• (1)tagbit_wrapper

Phrase Groups Available (6):
• global
• inlinemod
• postbit
• posting
• reputationlevel
Included Files (39):
• ./vbseo.php
• ./env.php
• ./vbseo/includes/functions_vbseo.php
• ./vbseo/includes/functions_vbseo_pre.php
• ./vbseo/includes/functions_vbseo_url.php
• ./vbseo/includes/functions_vbseo_createurl.php
• ./vbseo/includes/functions_vbseo_db.php
• ./vbseo/includes/functions_vbseo_vb.php
• ./vbseo/includes/functions_vbseo_seo.php
• ./vbseo/includes/functions_vbseo_misc.php
• ./vbseo/includes/functions_vbseo_crr.php
• ./vbseo/includes/functions_vbseo_cache.php
• ./vbseo/includes/functions_vbseo_hook.php
• ./vbseo/includes/functions_vbseo_startup.php
• ./includes/config.php
• ./global.php
• ./includes/class_bootstrap.php
• ./includes/init.php
• ./includes/class_core.php
• ./includes/functions.php
• ./includes/class_friendly_url.php
• ./includes/class_hook.php
• ./includes/functions_cforum.php
• ./includes/functions_bigthree.php
• ./includes/class_postbit.php
• ./includes/class_bbcode.php
• ./includes/functions_reputation.php
• ./includes/class_bootstrap_framework.php
• ./vb/vb.php
• ./vb/phrase.php
• ./packages/vbattach/attach.php
• ./vb/types.php
• ./vb/cache.php
• ./vb/cache/db.php
• ./vb/cache/observer/db.php
• ./vb/cache/observer.php
• ./includes/functions_notice.php

Hooks Called (49):
• init_startup
• friendlyurl_resolve_class
• database_pre_fetch_array
• database_post_fetch_array
• global_bootstrap_init_start
• global_bootstrap_init_complete
• cache_permissions
• fetch_foruminfo
• global_state_check
• global_bootstrap_complete
• global_start
• style_fetch
• global_setup_complete
• friendlyurl_redirect_canonical
• bbcode_fetch_tags
• bbcode_create
• postbit_factory
• postbit_display_start
• cache_templates
• template_register_var
• parse_templates
• notices_check_start
• notices_noticebit
• process_templates_complete
• reputation_image
• postbit_imicons
• bbcode_parse_start
• bbcode_parse_complete_precache
• bbcode_parse_complete
• postbit_display_complete
• memberaction_dropdown
• postbit_attachment
• tag_fetchbit_complete