OUTPUT1 (tab delimited)
Considering that in my case -e ND doesn't work I have to do this
OUTPUT2 (tab delimited)
Then for the 3th file...
OUTPUT3 (tab delimited)
Considering that in my case -e ND doesn't work I have to do this
OUTPUT4 (tab delimited)
--- --- ---
The point is that seem a little complicate my code... then, ofthe but not always I have problem with sorting... some time I have errors about sorting, when I apply the join command. I read that if I'm sure that my files are sorted I can bypass this sort-control-step of join command... but I want a new code without warnings...
Do you know any other command? Any help! commands, codes, script
Having N files I want to create a loop...
Many thanks!
echo manolis
Moderator's Comments:
Please use CODE tags (for data as well!) as required by forum rules!
Last edited by RudiC; 01-16-2018 at 06:27 PM..
Reason: Added CODE tags.
but I have the same sorting error in my original files. The files are sorted !!!
echo manolis
---------- Post updated at 09:21 AM ---------- Previous update was at 08:56 AM ----------
I saw several awk codes... I have to put my data in an array using an ID and match the line if they have the same ID... also to add in the output the lines that don't match
any help?
Last edited by echo manolis; 01-17-2018 at 05:11 AM..
but I have the same sorting error in my original files. The files are sorted !!!
echo manolis
---------- Post updated at 09:21 AM ---------- Previous update was at 08:56 AM ----------
I saw several awk codes... I have to put my data in an array using an ID and match the line if they have the same ID... also to add in the output the lines that don't match
any help?
Quote:
Originally Posted by echo manolis
Please, someone could let me know!
Best
echo manolis
When you tell us you have a sorting problem with your input files and tell us that your input files are sorted, you leave us wondering:
What is your sorting problem?
Why do you think there is a sorting problem?
What output did you get from your attempts to use join that led you to believe that you had a sorting problem?
As with all threads in this forum, you know that knowing what operating system you're using and what shell you're using helps us help you. And, you have not told us either of these key bits of information.
If echo -e doesn't work on your system (or in your shell), why not just use a literal tab character when specifying the field delimiter in your join commands? If you're afraid that someone reading your code won't be able to tell the difference between a <space> and a <tab>, why not include a comment in your code explaining that the delimiter is a <tab> character entered literally? If writing comments is unacceptable for you for some reason, why not use a command substitution that is portable:
or, if you're using a pure Bourne shell:
instead of using echo -e which is clearly not portable?
Why wait until you update post #3 in this thread to tell us what your real requirements are? Why not spend the time when you first started your thread to explain what you were trying to do? Why when you changed your requirements in post #3 didn't you include sample input and output that would help us understand what you're trying to do?
When you don't tell us what OS and shell you're using, don't clearly explain what you're trying to do, and don't show us sample input and corresponding output for the problem you're trying to solve; you make it hard for anyone to get interested in trying to help you.
When you give us details about your environment, give us a clear specification of what you're trying to do, show us sample inputs and outputs that correspond to that specification, and show us code that you have attempted to use to solve your problem on your own; you will be much more likely to get help.
Good Afternoon,
I'm backing up a folder from one NAS to another using a unix script using cp. Its a lot of files and takes several days to complete. Most of the files don't change from week to week. Is there a command that would be quicker?
Also note, the backup needs to be ready-to-use in... (5 Replies)
is there a different way to do the following:
curl -k -H "Content-Type:application/json" -X POST -d'{"api_token": "33blah526c-6bla71-441b-491b-0blahca08"}' https://10.10.10.10/api/1.4/auth/session -c /tmp/myhost01.myhost.com
im seeking to use a different method because i'm running into TLS... (1 Reply)
Hi All,
I am trying to select 30 days older files under current directory ,but not from subdirectory using below command.
find <Dir> -type f -mtime + 30
This command selecting all the files from current directory and also from sub directory .
I read some documention through internet ,... (1 Reply)
hi,
I need alternative command for topas to check cpu %, i tried with ps but their is lot of diffference between the outputs of two commands...
Thanks (3 Replies)
Hi,
I have 20 tab delimited text files that have a common column (column 1). The files are named GSM1.txt through GSM20.txt. Each file has 3 columns (2 other columns in addition to the first common column).
I want to write a script to join the files by the first common column so that in the... (5 Replies)
Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted!
Ok, Im back with another small problem. I created a script (the one posted in the last thread). After some help from some members here all is good. The problem is I made it... (4 Replies)
Hi all,
I am using linux box ...i dont find the manual entry of sar command through
man sar ...it is in unix not in linux although i have to check the cpu utilization and paging...any alternative of sar command..
Thanks
Vijay Sahu (1 Reply)
Hi friends,I am new to unix and this is really a dummy question.but please help me out.
How to simulate head command without using head command???
also tail command too,also more command.
it is given as a homework to do....please tell me how to do (2 Replies)
Hi,
I am a new learner of join command. Some result really make me confused.
Please kindly help me.
input:
file1:
LEO oracle engineer 210375
P.Jones Office Runner ID897
L.Clip Personl Chief ID982
S.Round UNIX admin ID6
file2:
Dept2C ID897 6 years
Dept5Z ID982 1 year
Dept3S ID6 2... (1 Reply)