Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
subString function in Excel(Urgent)
Hi,
I have some large database files in Excel and I want to put all the data in a single file. The problem is for putting all the data in single file is that I have to break "villageid" into 5 different numbers like suppose if I have a villageid 1234567891 the first two digit contains districid , the other two contains cityid, the other two contains townid etc. I need to break it into 5 different parts so that I can run the SQL query in Microsoft Excel to compare the data in other files. Like suppose I have 6 files. One contain two columns of villageid and name Other contains 10 columns of districtid and other facilities. Other contains 8 columns of cityid and functions. Other contains 5 columns of townid and seminars. similarly 2 other files are there. So, in order to fetch all the data in single file I need to break it into different number and need to compare it with columns in other file. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
subString function in Excel(Urgent)
Use the Mid function
For example, =Mid(A1,1,2) returns 2 digits starting at position 1 in the string - districtid =Mid(A1,3,2) returns cityid, and so on. Geoff "Varinder" wrote in message ... Hi, I have some large database files in Excel and I want to put all the data in a single file. The problem is for putting all the data in single file is that I have to break "villageid" into 5 different numbers like suppose if I have a villageid 1234567891 the first two digit contains districid , the other two contains cityid, the other two contains townid etc. I need to break it into 5 different parts so that I can run the SQL query in Microsoft Excel to compare the data in other files. Like suppose I have 6 files. One contain two columns of villageid and name Other contains 10 columns of districtid and other facilities. Other contains 8 columns of cityid and functions. Other contains 5 columns of townid and seminars. similarly 2 other files are there. So, in order to fetch all the data in single file I need to break it into different number and need to compare it with columns in other file. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
subString function in Excel(Urgent)
Thanks GB.
My Problem has been solved. Thanks very much. -----Original Message----- Use the Mid function For example, =Mid(A1,1,2) returns 2 digits starting at position 1 in the string - districtid =Mid(A1,3,2) returns cityid, and so on. Geoff "Varinder" wrote in message ... Hi, I have some large database files in Excel and I want to put all the data in a single file. The problem is for putting all the data in single file is that I have to break "villageid" into 5 different numbers like suppose if I have a villageid 1234567891 the first two digit contains districid , the other two contains cityid, the other two contains townid etc. I need to break it into 5 different parts so that I can run the SQL query in Microsoft Excel to compare the data in other files. Like suppose I have 6 files. One contain two columns of villageid and name Other contains 10 columns of districtid and other facilities. Other contains 8 columns of cityid and functions. Other contains 5 columns of townid and seminars. similarly 2 other files are there. So, in order to fetch all the data in single file I need to break it into different number and need to compare it with columns in other file. . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
IME MODE FOR EXCEL 2007 (URGENT URGENT) | Excel Discussion (Misc queries) | |||
Substring in excel? How about regular expressions? | Excel Discussion (Misc queries) | |||
Can excel macro access SUBstring individual 'char' level? If so how? | Excel Discussion (Misc queries) | |||
can I execute and 'substring' function in Excel | Excel Worksheet Functions | |||
Urgent help with a Function | Excel Discussion (Misc queries) |