+ Reply to Thread
Results 1 to 8 of 8

Find Function Assistance

  1. #1
    Registered User
    Join Date
    08-22-2006
    Posts
    18

    Find Function Assistance

    I have a spreadhseet with six workbooks that have 15 digit numbers in column A. On the 7th workbook I have a list of 9 digit numbers.

    I am looking for a foumula to search column A of workbooks 1-6 for each of the 9 digit numbers located on workbook seven. Any suggestions??

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464
    Hi,

    Are the 9 digit numbers the first 9 characters of the 15 digit number?
    What value do you want the formula to return? A Match() function for instance would return the row number.

    Rgds

  3. #3
    Registered User
    Join Date
    08-22-2006
    Posts
    18
    No, the 9 digits are not the first 9 of the 15.

    This is what I currently have, tailored to search one spreadsheet only.

    =IF(ISNUMBER(FIND(A2,'1'!A:A)),TRUE,FALSE)

    Cell A2 on the spreadsheet is the 9 digit number, and the 15 digit numbers are in column A of Worksheet 1.

    All my responses come back false, but if I alter the equation to search only the specific cell on Worksheet 1 that contains the information, then I get a True response.

    Example: =IF(ISNUMBER(FIND(A2,'1'!A4152)),TRUE,FALSE)

    Is there any way to alter this equation to search all cells in the column?

  4. #4
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464
    I don't know of any single function or series of functions that will achieve this. A FIND() works on characters in a cell, not cells in a column. Similarly a MATCH() works on whole cells in a column.

    The only option I fear would be a macro to test each cell with a FIND() (or in VBA syntax an Instr command), against every cell in the other sheet. Whilst that would be a simple macro to write, I suspect if you have over 4000 rows to search, and perhaps a similar number on the other sheet, then the number of combinations may rule it out because of the processing time.

    Is there nothing in the structure of the numbers, or perhaps other supporting data that could simplify the problem?

    Rgds

  5. #5
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898
    How about perhaps:

    =ISNUMBER(MATCH("*"&A2&"*",TEXT('1'!$A$1:$A$1000, "#"),0))

    which is an array formula and you must confirm with CTRL+SHIFT+ENTER.

    If you can make your entries in A1:A1000 text entries, then you don't need an array formula... you can use...ENTER only...

    =ISNUMBER(MATCH("*"&A2&"*",'1'!$A$1:$A$1000,0))

    Edit: forgot to say that for the second formula to work, the entries must be text strings...
    Last edited by NBVC; 05-09-2008 at 12:53 PM.
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  6. #6
    Registered User
    Join Date
    08-22-2006
    Posts
    18
    The 9 digit numbers are account numbers from an old company system. The 15 digit numbers are the new account numbers. The 9 digit numbers are still included in the 15 digit with one number before and five after. Ex: X123456789XXXXX

    I have tried the equations suggested but have had no luck.

    thanks all for your assistance.

  7. #7
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898
    My first formula must be confirmed with the CTRL, SHIFT and ENTER keys... and cannot reference whole column such as A:A....

  8. #8
    Registered User
    Join Date
    08-22-2006
    Posts
    18
    Excellent...I put in a line range instead of the column as a whole and it's working great.

    Thanks!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1