انتقل إلى المحتوى الرئيسي

كيفية استخراج قيم فريدة بناءً على معايير في Excel؟

لنفترض أن لديك نطاق البيانات الأيسر الذي تريد سرد الأسماء الفريدة للعمود B فقط بناءً على معيار محدد للعمود A للحصول على النتيجة كما هو موضح أدناه لقطة الشاشة. كيف يمكنك التعامل مع هذه المهمة في Excel بسرعة وسهولة؟

استخراج القيم الفريدة استناداً إلى المعايير باستخدام صيغة الصفيف

استخرج قيمًا فريدة استنادًا إلى معايير متعددة باستخدام صيغة صفيف

استخرج القيم الفريدة من قائمة الخلايا بميزة مفيدة

 

استخراج القيم الفريدة استناداً إلى المعايير باستخدام صيغة الصفيف

لحل هذه المهمة ، يمكنك تطبيق صيغة صفيف معقدة ، يرجى القيام بما يلي:

1. أدخل الصيغة أدناه في خلية فارغة حيث تريد سرد نتيجة الاستخراج ، في هذا المثال ، سأضعها في الخلية E2 ، ثم اضغط شيفت + كترل + إنتر مفاتيح للحصول على أول قيمة فريدة.

=IFERROR(INDEX($B$2:$B$15, MATCH(0, IF($D$2=$A$2:$A$15, COUNTIF($E$1:$E1, $B$2:$B$15), ""), 0)),"")

2. بعد ذلك ، اسحب مقبض التعبئة لأسفل إلى الخلايا حتى يتم عرض الخلايا الفارغة ، والآن تم إدراج جميع القيم الفريدة المستندة إلى المعيار المحدد ، انظر لقطة الشاشة:

ملحوظة: في الصيغة أعلاه: B2: B15 هو نطاق العمود الذي يحتوي على القيم الفريدة التي تريد الاستخراج منها ، A2: A15 هو العمود الذي يحتوي على المعيار الذي تستند إليه ، D2 يشير إلى المعيار الذي تريد سرد القيم الفريدة بناءً عليه ، و E1 هي الخلية الموجودة أعلى الصيغة التي أدخلتها.

استخرج قيمًا فريدة استنادًا إلى معايير متعددة باستخدام صيغة صفيف

إذا كنت ترغب في استخراج القيم الفريدة بناءً على شرطين ، فإليك صيغة صفيف أخرى يمكن أن تقدم لك خدمة ، يرجى القيام بذلك على النحو التالي:

1. أدخل الصيغة أدناه في خلية فارغة حيث تريد سرد القيم الفريدة ، في هذا المثال ، سأضعها في الخلية G2 ، ثم اضغط شيفت + كترل + إنتر مفاتيح للحصول على أول قيمة فريدة.

=IFERROR(INDEX($C$2:$C$15,MATCH(0,COUNTIF(G1:$G$1,$C$2:$C$15)+IF($A$2:$A$15<>$E$2,1,0)+IF($B$2:$B$15<>$F$2,1,0),0)),"")

2. بعد ذلك ، اسحب مقبض التعبئة لأسفل إلى الخلايا حتى يتم عرض الخلايا الفارغة ، والآن تم إدراج جميع القيم الفريدة بناءً على الشرطين المحددين ، انظر لقطة الشاشة:

ملحوظة: في الصيغة أعلاه: C2: C15 هو نطاق العمود الذي يحتوي على القيم الفريدة التي تريد الاستخراج منها ، A2: A15 و E2 هي النطاق الأول بالمعايير التي تريد استخراج قيم فريدة بناءً عليها ، B2: B15 و F2 هي النطاق الثاني بالمعايير التي تريد استخراج قيم فريدة بناءً عليها ، و G1 هي الخلية الموجودة أعلى الصيغة التي أدخلتها.

استخرج القيم الفريدة من قائمة الخلايا بميزة مفيدة

في بعض الأحيان ، تريد فقط استخراج القيم الفريدة من قائمة الخلايا ، هنا ، سأوصي بأداة مفيدة-كوتولس ل إكسيل، بما لديها استخراج الخلايا بقيم فريدة (تضمين أول تكرار) فائدة ، يمكنك استخراج القيم الفريدة بسرعة.

ملحوظة:لتطبيق هذا استخراج الخلايا بقيم فريدة (تضمين أول تكرار)أولاً ، يجب عليك تنزيل ملف كوتولس ل إكسيل، ثم قم بتطبيق الميزة بسرعة وسهولة.

بعد تثبيت كوتولس ل إكسيل، يرجى القيام بذلك على النحو التالي:

1. انقر فوق الخلية حيث تريد إخراج النتيجة. (ملاحظات: لا تنقر فوق خلية في الصف الأول.)

2. ثم اضغط كوتولس > مساعد الصيغة > مساعد الصيغة، انظر لقطة الشاشة:

3. في مساعد الصيغ مربع الحوار ، يرجى القيام بالعمليات التالية:

  • أختار نص الخيار من المعادلة النوع قائمة منسدلة؛
  • ثم اختر استخراج الخلايا بقيم فريدة (تضمين أول تكرار) من اختر فرومولا مربع القائمة
  • على اليمين مدخلات الحجج ، حدد قائمة الخلايا التي تريد استخراج القيم الفريدة.

4. ثم اضغط Ok الزر ، يتم عرض النتيجة الأولى في الخلية ، ثم حدد الخلية واسحب مقبض التعبئة إلى الخلايا التي تريد سرد جميع القيم الفريدة حتى تظهر الخلايا الفارغة ، انظر لقطة الشاشة:

تحميل مجاني Kutools لبرنامج Excel الآن!


المزيد من المقالات ذات الصلة:

  • عد عدد القيم الفريدة والمميزة من القائمة
  • لنفترض أن لديك قائمة طويلة من القيم مع بعض العناصر المكررة ، الآن ، تريد حساب عدد القيم الفريدة (القيم التي تظهر في القائمة مرة واحدة فقط) أو القيم المميزة (جميع القيم المختلفة في القائمة ، فهذا يعني فريد القيم + القيم المكررة الأولى) في عمود كما هو موضح في لقطة الشاشة اليسرى. في هذا المقال سأتحدث عن كيفية التعامل مع هذه الوظيفة في Excel.
  • جمع القيم الفريدة بناءً على المعايير في Excel
  • على سبيل المثال ، لدي مجموعة من البيانات التي تحتوي على أعمدة الاسم والنظام ، الآن ، لتلخيص القيم الفريدة فقط في عمود الأمر بناءً على عمود الاسم كما هو موضح في لقطة الشاشة التالية. كيف تحل هذه المهمة بسرعة وسهولة في Excel؟
  • تسلسل القيم الفريدة في Excel
  • إذا كانت لدي قائمة طويلة من القيم التي تم ملؤها ببعض البيانات المكررة ، فأنا الآن أرغب في العثور على القيم الفريدة فقط ثم تجميعها في خلية واحدة. كيف يمكنني التعامل مع هذه المشكلة بسرعة وسهولة في Excel؟

أفضل أدوات إنتاجية المكتب

🤖 مساعد Kutools AI: إحداث ثورة في تحليل البيانات على أساس: التنفيذ الذكي   |  إنشاء التعليمات البرمجية  |  إنشاء صيغ مخصصة  |  تحليل البيانات وإنشاء الرسوم البيانية  |  استدعاء وظائف Kutools...
الميزات الشعبية: البحث عن التكرارات أو تمييزها أو تحديدها   |  حذف الصفوف الفارغة   |  دمج الأعمدة أو الخلايا دون فقدان البيانات   |   جولة بدون صيغة 
سوبر بحث: معايير متعددة VLookup    VLookup ذات القيمة المتعددة  |   VLookup عبر أوراق متعددة   |   بحث غامض ....
قائمة منسدلة متقدمة: إنشاء القائمة المنسدلة بسرعة   |  القائمة المنسدلة التابعة   |  قائمة منسدلة متعددة التحديد ....
مدير العمود: إضافة عدد محدد من الأعمدة  |  نقل الأعمدة  |  تبديل حالة رؤية الأعمدة المخفية  |  مقارنة النطاقات والأعمدة 
الميزات المميزة: التركيز على الشبكة   |  عرض تصميم   |   شريط الفورمولا الكبير    مدير المصنفات والأوراق   |  مكتبة الموارد (النص السيارات)   |  منتقي التاريخ   |  اجمع أوراق العمل   |  تشفير/فك تشفير الخلايا    إرسال رسائل البريد الإلكتروني عن طريق القائمة   |  سوبر تصفية   |   مرشح خاص (تصفية غامق / مائل / يتوسطه خط ...) ...
أفضل 15 مجموعة أدوات12 نص الأدوات (إضافة نص, إزالة الأحرف، ...)   |   +50 رسم الأنواع (مخطط جانت، ...)   |   40+ عملي الصيغ (احسب العمر على أساس تاريخ الميلاد، ...)   |   19 إدخال الأدوات (أدخل رمز الاستجابة السريعة, إدراج صورة من المسار، ...)   |   12 تحويل الأدوات (أرقام إلى كلمات, نتيجة تحويل عملة، ...)   |   7 دمج وتقسيم الأدوات (الجمع بين الصفوف المتقدمة, تقسيم الخلايا، ...)   |   ... و اكثر

عزز مهاراتك في Excel باستخدام Kutools for Excel، واختبر كفاءة لم يسبق لها مثيل. يقدم Kutools for Excel أكثر من 300 ميزة متقدمة لتعزيز الإنتاجية وتوفير الوقت.  انقر هنا للحصول على الميزة التي تحتاجها أكثر...

الوصف


يجلب Office Tab الواجهة المبوبة إلى Office ، ويجعل عملك أسهل بكثير

  • تمكين التحرير والقراءة المبوبة في Word و Excel و PowerPointوالناشر والوصول و Visio والمشروع.
  • فتح وإنشاء مستندات متعددة في علامات تبويب جديدة من نفس النافذة ، بدلاً من النوافذ الجديدة.
  • يزيد من إنتاجيتك بنسبة 50٪ ، ويقلل مئات النقرات بالماوس كل يوم!
Comments (40)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
Thank you so much. This was very very helpful. You Rock!!
This comment was minimized by the moderator on the site
hi everyone..
i have problem..
i got blank result even i press ctrl shift enter together..
This comment was minimized by the moderator on the site
Hi all, Can some help me to get all unique values on one single cell
This comment was minimized by the moderator on the site
Hi, this worked well! Although it takes Excel sooooo long to calculate. Just dragging down 15 cells in a column takes about 15min to calculate... if not longer. Is this normal? If this becomes dynamic it will take a hell of alot of computing time.
This comment was minimized by the moderator on the site
Hello. This is really helpful, however, what If I want a formula that lists the unique values based on multiple criteria. eg. I have a data set which has the following data in a table (after each hyphen is a new column but same row):

Company A - £200 - £100
Company A - £300 - £200
Company B - £300 - £200
Company C - £600 - £200
Company B - £100 - £300
Company D - £0 - £600
Company A - £700 - £100

I want a new data table in a new tab which groups the duplicate values without using an array formula. currently I'm grouping using a pivot table and pasting to my new data table. It's a long process but array formulas make my spreadsheet really slow.

Company A - £1200 - £400
Company B - £400 - £500
Company C - £600 - £200
Company D - £0 - £600

Thanks,
K
This comment was minimized by the moderator on the site
Hello, K,
For solving your problem, I can recommend our useful tool- Kutools for Excel, with its Advanced Combine Rows feature, you can deal with this job quickly. Firstly, you should copy and paste your data into a new worksheet, and then apply htis feature as below screenhsot shown.
You can know more about this feature from: https://www.extendoffice.com/product/kutools-for-excel/excel-combine-duplicate-rows.html
Please download Kutools for Excel and install it, then apply this feature. Full feature free trial 30-day, please try.
This comment was minimized by the moderator on the site
Hi! the formula works really well. I would like to add another criterion, i mean, get the unique answers but using two criteria
This comment was minimized by the moderator on the site
Hi, Giancarlo,
to extract unique values based on multiple criteria, any of the below formula can help you: (after pasting the formula, please press Ctrl + Shift + Enter keys together.)
=IFERROR(INDEX($C$2:$C$11, MATCH(0, COUNTIF(G1:$G$1, $C$2:$C$11)+IF($A$2:$A$11<>$E$2, 1, 0)+IF($B$2:$B$11<>$F$2, 1, 0), 0)), "")
=INDEX($C$2:$C$11, MATCH(0, IF(($A$2:$A$11=$E$2)*($B$2:$B$11=$F$2), COUNTIF($G$1:$G1, $C$2:$C$11), ""), 0))
Please try, hope it can help you!
This comment was minimized by the moderator on the site
Hi. I am using the two conditions formula =IFERROR(INDEX($C$2:$C$11, MATCH(0, COUNTIF(G1:$G$1, $C$2:$C$11)+IF($A$2:$A$11<>$E$2, 1, 0)+IF($B$2:$B$11<>$F$2, 1, 0), 0)), "") to extract a unique list and it works great, but I am struggle to add the SMALL function to get the list sorted as well in ascending order. Are you able to help?
This comment was minimized by the moderator on the site
Is there a way to make this work while ALLOWING for duplicate values? For instance, I want all instances of Lucy to be listed in the results.
This comment was minimized by the moderator on the site
Hello, Konstantin,
To extract all corresponding values including the duplicates based on a specific cell criteria, the following array formula can help you, see screenshot:
=IF(ISERROR(INDEX($A$1:$B$17,SMALL(IF($A$1:$A$17=$D$2,ROW($A$1:$A$17)),ROW(1:1)),2)),"",
INDEX($A$1:$B$17,SMALL(IF($A$1:$A$17=$D$2,ROW($A$1:$A$17)),ROW(1:1)),2))

After inserting the formula, please press Shift + Ctrl + Enter keys together to get the correct result, and then drag the fill handle down to get all values.
Hope this can help you, thank you!
This comment was minimized by the moderator on the site
This has worked great for me with a specific lookup value. However, if I wanted to use a wildcard to look up partial values, how would I do that? For example, if I wanted to lookup all the names associated with KT?

I am using this function to look up cells that contain multiple text. For example if each product also had a sub-product within the same cell but I was only looking for names associated with the sub-product "elf".

KTE - elf
KTE- ball
KTE - piano
KTO - elf
KTO- ball
KTO - piano
This comment was minimized by the moderator on the site
For me the formula does not work. I press ctrl shift enter and i still get an error N/A. I would like to add that i prpared exaclty the same data as in tutorial. What is the reason it does not work?
This comment was minimized by the moderator on the site
How would I get this formula to return each of the duplicates instead of one of each of the names? For instance, in the example above, how would I get the results column (B:B) to return Lucy, Ruby, Anny, Jose, Lucy, Anny, Tom? I'm using this as a budget tool pulling to specific account summaries from a general ledger. However, several of the amounts and transaction descriptions are duplicates in the general ledger. Once the first of the duplicated values is pulled, no more of them get pulled.
This comment was minimized by the moderator on the site
Hi, Joe,
To extract all corresponding values based on a specific cell criteria, the following array formula can help you, see screenshot:
=IF(ISERROR(INDEX($A$1:$B$17,SMALL(IF($A$1:$A$17=$D$2,ROW($A$1:$A$17)),ROW(1:1)),2)),"",
INDEX($A$1:$B$17,SMALL(IF($A$1:$A$17=$D$2,ROW($A$1:$A$17)),ROW(1:1)),2))

After inserting the formula, please press Shift + Ctrl + Enter keys together to get the correct result, and then drag the fill handle down to get all values.
Hope this can help you, thank you!
This comment was minimized by the moderator on the site
Last Question: If I want the results column to return all values not associated with KTE or KTO (so, D:D would be Tom, Nocol, Lily, Angelina, Genna), how would I do that?
This comment was minimized by the moderator on the site
Ok, so it works in the master workbook. There is one exception that I haven't been able to determine the cause of: If the array (in my case, the general ledger that I had beginning in row 3) does not begin in Row 1, the returned values are incorrect. What causes this problem, and which term in the formula fixes it? Thanks again for your help with this!
This comment was minimized by the moderator on the site
So far so good. I'm able to duplicate the results in the test sheet, make changes to the array, and then correct the formula to account for the changes I've made. I plan to move this into the master sheet today and see how it works. Thanks for the help!
There are no comments posted here yet
Load More
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations