![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| AIX AIX is IBM's industry-leading UNIX operating system that meets the demands of applications that businesses rely upon in today's marketplace. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Combining two files | hemangjani | Shell Programming and Scripting | 7 | 06-13-2007 10:32 PM |
| Combining Two Files | stevefox | Shell Programming and Scripting | 4 | 02-20-2006 05:09 AM |
| Combining Two Files | bat711 | Shell Programming and Scripting | 3 | 10-05-2005 01:26 PM |
| Combining files | Enda Martin | UNIX for Dummies Questions & Answers | 2 | 07-20-2001 10:31 AM |
| combining files | apalex | UNIX for Dummies Questions & Answers | 3 | 06-19-2001 09:49 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
combining two input text files
hi!
i would like to process two input text files text1 9835023 20051004F2_011 9835021 20060904FAL0132006 8835099 20051004HOL011 8835044 20051004H1_011 6835023 20061002HAL0132006 4835099 20050721F1_011 4835088 20050906F1_011 4835044 20060905FAL0132006 4835023 20061001HAL0132006 4835021 20050816FAL011 3835023 20050707F1_011 2835021 20050531SM2011 text2 20050531SM2011 20050707F1_011 20050721F1_011 20050816FAL011 20050906F1_011 20051004F2_011 20051004H1_011 20051004HOL011 what i would like to happen is to combine those two, if text2 find its match in text1 (please see below) final combination (output) text3 9835023 20051004F2_011 20051004F2_011 9835021 20060904FAL0132006 8835099 20051004HOL011 20051004HOL011 8835044 20051004H1_011 20051004H1_011 6835023 20061002HAL0132006 4835099 20050721F1_011 20050721F1_011 4835088 20050906F1_011 20050906F1_011 4835044 20060905FAL0132006 4835023 20061001HAL0132006 4835021 20050816FAL011 20050816FAL011 3835023 20050707F1_011 20050707F1_011 2835021 20050531SM2011 20050531SM2011 i would like to know the proper coding for this thanks for the help -->in advance -d3ck_tm Last edited by d3ck_tm; 02-28-2006 at 03:29 AM.. Reason: typographical error |
|
||||
|
Quote:
My concern now is about the input file format. When I joined the two files. text1 9835023 20051004F2_011 9835021 20060904FAL0132006 8835099 20051004HOL011 8835044 20051004H1_011 6835023 20061002HAL0132006 4835099 20050721F1_011 4835088 20050906F1_011 4835044 20060905FAL0132006 4835023 20061001HAL0132006 4835021 20050816FAL011 3835023 20050707F1_011 2835021 20050531SM2011 text2 20050531SM2011 20050707F1_011 20050721F1_011 20050816FAL011 20050906F1_011 20051004F2_011 20051004H1_011 20051004HOL011 Actually file text1 have format, field1 and field2 suppose to have 20 charaters including the spaces. X = represents spaces 9835023XXXXXXXXXXXXX20051004F2_011XXXXXX questions: 1. can the JOIN command consider the spaces set in text1 file? 2. do i have to use some flags for this? Please let me know. My goal is to have an output like this(below) X = represents spaces 9835023XXXXXXXXXXXXX20051004F2_011XXXXXX20051004F2_011XXXXXX thanks for your help cheers! --d3ck_tm |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|