Sponsored Content
Top Forums Shell Programming and Scripting Joining files using awk not extracting all columns from File 2 Post 302970584 by venkat_reddy on Friday 8th of April 2016 09:56:49 AM
Old 04-08-2016
@rdrtx1:

Code suggested by you worked. Thanks a lot

@Ravinder:

I did try out the code suggested by you but its giving me same output which I was getting earlier. I need all the columns from the File 2 .Anyways thanks much for the response
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Joining columns from two files, if the key matches

I am trying to join/paste columns from two files for the rows with matching first field. Any help will be appreciated. Files can not be sorted and may not have all rows in both files. Thanks. File1 aaa 111 bbb 222 ccc 333 File2 aaa sss mmmm ccc kkkk llll ddd xxx yyy Want to... (1 Reply)
Discussion started by: sk_sd
1 Replies

2. Shell Programming and Scripting

Joining two files based on columns/fields

I've got two files, File1 and File2 File 1 has got combination of col1, col2 and col3 which comes on file2 as well, file2 does not get col4. Now based on col1, col2 and col3, I would like to get col4 from file1 and all the columns from file2 in a new file Any ideas? File1 ------ Col1 col2... (11 Replies)
Discussion started by: rudoraj
11 Replies

3. Shell Programming and Scripting

extracting columns with awk

Friends, I have a file with fileds in the following order sda 4.80 114.12 128.69 978424 1103384 sdb 0.03 0.40 0.00 3431 0 sda 1.00 0.00 88.00 0 176 sdb ... (14 Replies)
Discussion started by: achak01
14 Replies

4. Shell Programming and Scripting

Transposing column to row, joining with another file, then sorting columns

Hello! I am very new to Linux and I do not know where to begin... I have a column with >64,000 elements (that are not in numberical order) like this: name 2 5 9 . . . 64,000 I would like to transpose this column into a row that will later become the header of a very large file... (2 Replies)
Discussion started by: doobedoo
2 Replies

5. UNIX for Dummies Questions & Answers

Extracting columns from multiple files with awk

hi everyone! I already posted it in scripts, I'm sorry, it's doubled I'd like to extract a single column from 5 different files and put them together in an output file. I saw a similar question for 2 input files, and the line of code workd very well, the code is: awk 'NR==FNR{a=$2; next}... (1 Reply)
Discussion started by: orcaja
1 Replies

6. Shell Programming and Scripting

Extracting columns from multiple files with awk

hi everyone! I'd like to extract a single column from 5 different files and put them together in an output file. I saw a similar question for 2 input files, and the line of code workd very well, the code is: awk 'NR==FNR{a=$2; next} {print a, $2}' file1 file2 I added the file3, file4 and... (10 Replies)
Discussion started by: orcaja
10 Replies

7. Shell Programming and Scripting

NR==FNR trick for joining columns from two files

foo.txt 1 rs2887286 0 1145994 C T 1 rs1240743 0 1323299 C A 1 rs1695824 0 1355433 G T 1 rs3766180 0 1468016 G A 1 rs7519837 0 1500664 A G 1 rs2272908 0 ... (12 Replies)
Discussion started by: genehunter
12 Replies

8. Shell Programming and Scripting

Other alternative for joining together columns from multiple files

Hi again, I have monthly one-column files of roughly around 10 years. Is there a more efficient way to concatenate these files column-wise other than using paste command? For instance: file1.txt 12 13 15 12 file2.txt 14 15 18 19 file3.txt 20 21 (8 Replies)
Discussion started by: ida1215
8 Replies

9. UNIX for Dummies Questions & Answers

Joining different columns from multiple files

Hello again, I am trying to join 3rd column of 3 files into the end on one file and save it separately... my data looks like this file 1 Bob, Green, 80 Mark, Brown, 70 Tina, Smith, 60 file 2 Bob, Green, 70 Mark, Brown, 60 Tina, Smith, 50 file 3 Bob, Green, 50 Mark, Brown,60 Tina,... (6 Replies)
Discussion started by: A-V
6 Replies

10. Shell Programming and Scripting

Joining Two Files Matching Two Columns

Hi All, I am looking to join two files where column 1 of file A matches with column 1 of file B and column 5 of files A matches with column 2 of file B. After joining the files based on above condition, out should contain entire line of file A and column 3, 4 and 5 of file B. Here is sample... (8 Replies)
Discussion started by: angshuman
8 Replies
nscd.conf(4)							   File Formats 						      nscd.conf(4)

NAME
nscd.conf - name service cache daemon configuration SYNOPSIS
/etc/nscd.conf DESCRIPTION
The nscd.conf file contains the configuration information for nscd(1M). Each line specifies either an attribute and a value, or an attribute, cachename, and a value. Fields are separated either by SPACE or TAB characters. A `#' (number sign) indicates the beginning of a comment; characters up to the end of the line are not interpreted by nscd. cachename is represented by hosts, ipnodes, passwd, group, exec_attr, prof_attr, user_attr, ethers, rpc, protocols, networks, bootparams, audit_user, auth_attr, services, netmasks, printers, or project. The attribute field supports the following: check-files cachename value Enables or disables checking the file belonging to the specified cachename for changes. If enabled (which is the default), changes in the corresponding file cause the cache to be invalidated within 10 seconds. Can be disabled if files are never modified for a slight performance boost, particularly over NFS. value may be either yes or no. debug-level value Sets the debug level desired. value may range from 0 (the default) to 10. Use of this option causes nscd(1M) to run in the foreground and not become a daemon. Note that the output of the debugging command is not likely to remain the same from release-to-release; scripts should not rely on its format. enable-cache cachename value Enables or disables the specified cache. value may be either yes or no. enable-per-user-lookup value Enables or disables the ability of nscd to create a per-user nscd. A per-user nscd performs per-user lookups and manages the per-user cache. The per-user lookups might not be possible if the corresponding name service switch backends do not support it or are not con- figured to do so. The value of this attribute can be either yes or no. keep-hot-count cachename value This attribute allows the administrator to set the number of entries nscd(1M) is to keep current in the specified cache. value is an integer number which should approximate the number of entries frequently used during the day. logfile debug-file-name Specifies name of the file to which debug info should be written. Use /dev/tty for standard output. maximum-per-user-nscd value Sets the maximum number of per-user nscds that can be created and managed by the main nscd daemon. The value is an integer. negative-time-to-live cachename value Sets the time-to-live for negative entries (unsuccessful queries) in the specified cache. value is in integer seconds. Can result in significant performance improvements if there are several files owned by uids (user IDs) not in system databases; should be kept small to reduce cache coherency problems. per-user-nscd-time-to-live value Sets the time-to-live value for a per-user nscd based on the last time the per-user nscd was active. The value is an integer that spec- ifies a number of seconds. positive-time-to-live cachename value Sets the time-to-live for positive entries (successful queries) in the specified cache. value is in integer seconds. Larger values increase cache hit rates and reduce mean response times, but increase problems with cache coherence. Note that sites that push (update) NIS maps nightly can set the value to be the equivalent of 12 hours or more with very good performance implications. suggested-size cachename value Sets the suggested number of hash buckets in the specified cache. This parameter should be changed only if the number of entries in the cache exceeds the suggested size by more than a factor of four or five. Since this is the internal hash table size, value should remain a prime number for optimum efficiency. This attribute is obsolete and will be silently ignored. nscd now automatically adjusts the hash table size. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availibility |SUNWcsu | +-----------------------------+-----------------------------+ |Interface Stability |Committed | +-----------------------------+-----------------------------+ SEE ALSO
nscd(1M), audit_user(4), auth_attr(4), bootparams(4), ethers(4), exec_attr(4), group(4), hosts(4), netmasks(4), networks(4), passwd(4), printers(4), prof_attr(4), project(4), protocols(4), rpc(4), services(4), user_attr(4), attributes(5) SunOS 5.11 21 Aug 2006 nscd.conf(4)
All times are GMT -4. The time now is 08:49 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy