मुख्य सामग्री पर जाएं

एक्सेल में टेक्स्ट स्ट्रिंग में पहले/आखिरी नंबर की स्थिति कैसे पता करें?

लेखक: सिलुविया अंतिम संशोधित: 2020-07-01

उदाहरण के लिए, आपके पास टेक्स्ट स्ट्रिंग की एक सूची है जो अक्षरों और संख्याओं का मिश्रण है। यदि आप प्रत्येक स्ट्रिंग में प्रथम या अंतिम संख्या का स्थान ज्ञात करना चाहें, तो आप क्या करेंगे? दरअसल, सूत्र का उपयोग करने से आपको निर्दिष्ट टेक्स्ट स्ट्रिंग में पहली/अंतिम संख्या की स्थिति तुरंत ढूंढने में मदद मिलेगी। इस ट्यूटोरियल में, हम आपको इस समस्या से निपटने का विवरण दिखाएंगे।

एक्सेल में टेक्स्ट स्ट्रिंग में पहले नंबर की स्थिति ढूंढें
Excel में टेक्स्ट स्ट्रिंग में अंतिम संख्या की स्थिति ज्ञात करें


एक्सेल में टेक्स्ट स्ट्रिंग में पहले नंबर की स्थिति ढूंढें

जैसा कि नीचे स्क्रीनशॉट में दिखाया गया है, टेक्स्ट स्ट्रिंग्स में पहले नंबरों की स्थिति खोजने के लिए, कृपया निम्नानुसार कार्य करें।

1. सेल B2 का चयन करें, नीचे दिए गए फॉर्मूले में से किसी एक को कॉपी करें और फॉर्मूला बार में पेस्ट करें:

1). सूत्र 1: =MIN(खोज({0,1,2,3,4,5,6,7,8,9},A2&"0123456789"));

2). सूत्र 2: =MATCH(TRUE,ABS(CODE(MID(A2,ROW($A$1:INDEX(A:A,LEN(A2))),1))-52.5)<5,0) + कंट्रोल + पाली + दर्ज;

3). सूत्र 3: =MIN(IF(ISERROR(FIND({1;2;3;4;5;6;7;8;9;0},A2)),"",FIND({1;2;3;4;5;6;7;8;9;0},A2))).

2. फिर सेल B2 में पहली स्ट्रिंग की पहली संख्या की स्थिति प्रदर्शित हो रही है। अब नीचे दी गई रेंज को भरने के लिए फिल हैंडल को सेल B7 तक नीचे खींचें।

फिर संपूर्ण स्ट्रिंग्स की सभी प्रथम संख्या स्थितियाँ सूचीबद्ध की जाती हैं।


Excel में टेक्स्ट स्ट्रिंग में अंतिम संख्या की स्थिति ज्ञात करें

पहली संख्या की स्थिति ज्ञात करने के बाद, अब हम स्ट्रिंग में अंतिम संख्या की स्थिति ज्ञात करना शुरू करते हैं।

इस अनुभाग में, आपके लिए दो सूत्र हैं।

फ़ॉर्मूला 1: =MAX(IF(ISNUMBER(मान(MID(A2,ROW(अप्रत्यक्ष("1:" और LEN(A2))),1))),पंक्ति(अप्रत्यक्ष("1:" और LEN(A2)))) ) + कंट्रोल + पाली + दर्ज;

फ़ॉर्मूला 2: =MAX(IFERROR(FIND({1,2,3,4,5,6,7,8,9,0},A2,ROW(INDIRECT("1:"&LEN(A2)))),0)) + कंट्रोल + पाली + दर्ज

1. सेल B2 का चयन करें, उपरोक्त सूत्रों में से एक को कॉपी करें और फॉर्मूला बार में पेस्ट करें, फिर Ctrl + Shift + Enter कुंजी एक साथ दबाएं। फिर आप परिणाम को B2 में प्रदर्शित होते देख सकते हैं।

2. बी2 का चयन करें, रेंज को स्वत: भरने के लिए फिल हैंडल को सेल बी7 तक नीचे खींचें।

फिर आपको संपूर्ण टेक्स्ट स्ट्रिंग के सभी अंतिम नंबरों की स्थिति तुरंत मिल जाएगी।


एक्सेल में टेक्स्ट और नंबर को एक सेल से दो कॉलम में आसानी से अलग करें:

- एक्सेल के लिए कुटूलहै विभाजन कोशिकाओं उपयोगिता, आप विशिष्ट विभाजक द्वारा कोशिकाओं की एक श्रृंखला को पंक्तियों या स्तंभों में विभाजित कर सकते हैं, पाठ और संख्याओं को विभाजित कर सकते हैं या प्रमाणित लंबाई के आधार पर पाठ को विभाजित कर सकते हैं। अभी डाउनलोड करें और इसे आज़माएं! (30 दिन का निःशुल्क ट्रेल)


संबंधित आलेख:

सर्वोत्तम कार्यालय उत्पादकता उपकरण

🤖 कुटूल्स एआई सहयोगी: निम्न के आधार पर डेटा विश्लेषण में क्रांति लाएं: बुद्धिमान निष्पादन   |  कोड जनरेट करें  |  कस्टम फ़ॉर्मूले बनाएं  |  डेटा का विश्लेषण करें और चार्ट बनाएं  |  कुटूल फ़ंक्शंस का आह्वान करें...
लोकप्रिय सुविधाएँ: डुप्लिकेट ढूंढें, हाइलाइट करें या पहचानें   |  रिक्त पंक्तियाँ हटाएँ   |  डेटा खोए बिना कॉलम या सेल को संयोजित करें   |   फॉर्मूला के बिना गोल ...
सुपर लुकअप: एकाधिक मानदंड VLookup    मल्टीपल वैल्यू वीलुकअप  |   अनेक शीटों में VLookup   |   फजी लुकअप ....
उन्नत ड्रॉप-डाउन सूची: शीघ्रता से ड्रॉप डाउन सूची बनाएं   |  आश्रित ड्रॉप डाउन सूची   |  बहु-चयन ड्रॉप डाउन सूची ....
स्तम्भ प्रबंधक: कॉलमों की एक विशिष्ट संख्या जोड़ें  |  कॉलम ले जाएँ  |  छिपे हुए कॉलम की दृश्यता स्थिति टॉगल करें  |  रेंज और कॉलम की तुलना करें ...
फीचर्ड फीचर्स: ग्रिड फोकस   |  डिजाइन देखें   |   बड़ा फॉर्मूला बार    कार्यपुस्तिका एवं शीट प्रबंधक   |  संसाधन लाइब्रेरी (ऑटो टेक्स्ट)   |  खजूर बीनने वाला   |  कार्यपत्रकों को संयोजित करें   |  एन्क्रिप्ट/डिक्रिप्ट सेल    सूची के अनुसार ईमेल भेजें   |  सुपर फ़िल्टर   |   विशेष फ़िल्टर (फ़िल्टर बोल्ड/इटैलिक/स्ट्राइकथ्रू...) ...
शीर्ष 15 टूलसेट12 टेक्स्ट टूल्स (पाठ जोड़ें, अक्षर हटाएँ, ...)   |   50 + चार्ट प्रकार (गैन्ट चार्ट, ...)   |   40+ प्रैक्टिकल सूत्र (जन्मदिन के आधार पर आयु की गणना करें, ...)   |   19 निवेशन टूल्स (QR कोड डालें, पथ से चित्र सम्मिलित करें, ...)   |   12 रूपांतरण टूल्स (शब्दों को संख्याएँ, मुद्रा रूपांतरण, ...)   |   7 विलय और विभाजन टूल्स (उन्नत संयोजन पंक्तियाँ, विभाजन कोशिकाओं, ...)   |   ... और अधिक

एक्सेल के लिए कुटूल के साथ अपने एक्सेल कौशल को सुपरचार्ज करें, और पहले जैसी दक्षता का अनुभव करें। एक्सेल के लिए कुटूल उत्पादकता बढ़ाने और समय बचाने के लिए 300 से अधिक उन्नत सुविधाएँ प्रदान करता है।  वह सुविधा प्राप्त करने के लिए यहां क्लिक करें जिसकी आपको सबसे अधिक आवश्यकता है...

Description


ऑफिस टैब ऑफिस में टैब्ड इंटरफ़ेस लाता है, और आपके काम को बहुत आसान बनाता है

  • Word, Excel, PowerPoint में टैब्ड संपादन और रीडिंग सक्षम करें, प्रकाशक, एक्सेस, विसियो और प्रोजेक्ट।
  • नई विंडो के बजाय एक ही विंडो के नए टैब में एकाधिक दस्तावेज़ खोलें और बनाएं।
  • आपकी उत्पादकता 50% बढ़ जाती है, और आपके लिए हर दिन सैकड़ों माउस क्लिक कम हो जाते हैं!
Comments (15)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
Ich habe gerade diese Lösung ausprobiert und es klappt bei mir nicht. Hat sich inzwischen etwas, was die Matrixformel betrifft, geändert?
This comment was minimized by the moderator on the site
Hi Wolfgang,

The formulas provided in this post work well in my case. What result did you get?
This comment was minimized by the moderator on the site
Thought I would let everyone know that I needed to find the last position of the house numbers in an address field in access. The only way I could do this was to export a short query to excel and run this formula. I know there is a way to get the excel functions in access but this was much easier. I had addresses that had varying house number lengths and then you throw in the 1st, 2nd, 3rd...St., Ave into the mix within the street name and you got a major problem parsing a very bad formatted address string.

address examples 1234 nw (or NW) 4th St.
12 West St North (or N)
123,456, and 789 Heritage Circle (or Crc)
123 & 456 N 1st. St

I figured out a way to parse off the first and second example real quick with some research (I would give credit, but right now I can't remember where I got the answer). It involved creating a VBA function to accomplish it. That worked great but I came to a problem when we come to the first "," or "and" or "&".

Using this formula in excel found the last number I needed without choosing the street number. Since most house numbers ended with a space " " between them and the direction segment or the street name segment, I added --- &" " after the find formula. Like this: in an array formula
=MAX(IFERROR(FIND({1,2,3,4,5,6,7,8,9,0}&" ",E2,ROW(INDIRECT("1:"&LEN(E2)))),0))
A quick export back to an access table and wala! you have the number.
202 & 206 N Blanche Ave = 9

Now I know I could probably parse the rest of the address in excel but it actually worked real well in Access, so I just decided to do the rest there.

If there is a way to do it all in Access, I couldn't find it or figure it out.
This comment was minimized by the moderator on the site
goood, thanks
This comment was minimized by the moderator on the site
That's what I needed =MIN(SEARCH({0,1,2,3,4,5,6,7,8,9},A2&"0123456789"));

thank you very much!
This comment was minimized by the moderator on the site
You are welcome O(∩_∩)O
This comment was minimized by the moderator on the site
how to get this to work in powerpivot
This comment was minimized by the moderator on the site
Hi,
Sorry can't help with this.
This comment was minimized by the moderator on the site
.... and here I thought that I knew Excel well. Bravo!!!!!
This comment was minimized by the moderator on the site
And here is a formula for finding the position of the last numeric character in a string, but WITHOUT using an array formula: =MAX(SEARCH(CHAR(9),SUBSTITUTE("0123456789"&A1,{0,1,2,3,4,5,6,7,8,9},CHAR(9),LEN(A1)+10-LEN(SUBSTITUTE("0123456789"&A1,{0,1,2,3,4,5,6,7,8,9},"")))))-10 The number 10 appearing in this formula, are due to the length of the constant string "0123456789", that is concatenated in this formula.
This comment was minimized by the moderator on the site
Many Thanks , Great
This comment was minimized by the moderator on the site
Hi George, your formula is may meet my requirement. I need similar formula to find out digit position in the string listed in "A" row in B row Required output 8 5 1 4 3 1 3 2 5 5 6 6 1 7 9 9 1 1 6 0 9 3 0 2 7 4 9 3 6 5 5 7 4 9 8 10 2 10 0 8 1 9
This comment was minimized by the moderator on the site
This was exactly what I wanted. Thank you.
This comment was minimized by the moderator on the site
The function 1). Formula 1: =MIN(SEARCH({0,1,2,3,4,5,6,7,8,9},A2&"0123456789")); It's absolutely what i needed and extremely cool! Thanks so much! Jon
This comment was minimized by the moderator on the site
Hats off mate..
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations