07-10-2009
Of course. First 3 rows are enough, use head -3.
9 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi All,
I have a sequential file, with that I want to know row count within.
As know we can use, wc -l filename, to find out a row count.
But, I found this command works well , if a file is small. It fails to give me rowcount, if File is pretty big. It keeps on processing after we give the... (3 Replies)
Discussion started by: videsh77
3 Replies
2. Shell Programming and Scripting
All,
I have to create a shell script to comapre the rowcount of 120 tables from two oracle databases. In fact, using informatica the data is loading from 120 source tables to 120 staging tables. After that, they want to have a shell script to comapre the rowcount of all these tables.
1) I... (3 Replies)
Discussion started by: Maya_Pillai
3 Replies
3. Shell Programming and Scripting
Hi
Can anyone what I am doing wrong while using cut command.
for f in *.log
do
logfilename=$f
Log "Log file Name: $logfilename"
logfile1=`basename $logfilename .log`
flength=${#logfile1}
Log "file length $flength"
from_length=$(($flength - 15))
Log "from... (2 Replies)
Discussion started by: dgmm
2 Replies
4. Shell Programming and Scripting
Dear All,
I have a requirement in which i have to load a file placed in FTP location onto my database. The process i'll follow is as below:
1) Get the files using FTP.
2) Create the desired load files as i have to load only 19 fields out of the 104 available in the file.
The fields i require... (7 Replies)
Discussion started by: abhishekakaomi
7 Replies
5. Shell Programming and Scripting
Dears,
i want cut the lines from a log file. Example of the log file as follows..
May 27, 2011 5:54:51 PM com.huawei.ivas.utilities.sm.client.SMDeliverContrUtil isDeliverSM
FINE:
May 27, 2011 5:54:51 PM com.huawei.ivas.utilities.sm.client.SMUtil addSysUpMsgLog
INFO: . The message content... (1 Reply)
Discussion started by: tonypalokkaran
1 Replies
6. Shell Programming and Scripting
Hi,
I am working on one script..I am having files in the below format
file 1 (each line is separated with : delimeter)
SPLASH:SPLASH:SVN
CIB/MCH:MCH:SVN
Now I want from file 1 that most left part of the first line will store in... (6 Replies)
Discussion started by: rohit22hamirpur
6 Replies
7. Shell Programming and Scripting
Hi,
First of all sincere apologies if I have posted in a wrong section ! Please correct me if I am wrong !
I am very new to UNIX scripting.
Currently my problem is that I have a code file at the location /home/usr/workarea/GeneratedLogs.log :-
Code :-
(Feb 7, 571 7:07:29 AM),... (4 Replies)
Discussion started by: acidburn_007
4 Replies
8. Shell Programming and Scripting
Hello ppl
I have a requirement to split (cut in unix) a file (A.txt) which is a pipe delimited file into A1.txt and A2.txt
Now I have to join (paste in unix) this A2.txt with external file A3.txt to form
output file A4.txt which should be CSV (comma separated file) so that third party can... (25 Replies)
Discussion started by: etldev
25 Replies
9. Shell Programming and Scripting
I am using : << cut / cut to comment out block of code.
Works fine on few lines of script, then it gives me this cryptic error when I try to comment out about 80 lines.
The "warning " is at last line of script.
done < results
169 echo "END read all positioning parameters"
170... (8 Replies)
Discussion started by: annacreek
8 Replies
LEARN ABOUT DEBIAN
dtfits
dtfits(1) General Commands Manual dtfits(1)
NAME
dtfits - display FITS table
SYNOPSIS
dtfits <table>
DESCRIPTION
dtfits dumps the contents of a FITS table in an ASCII format, either into a user-specified file or on stdout. The output is formatted on a
fixed number of columns to make it readable by human beings. Additional informations are printed out before the table values are dumped,
these informations can be skipped by using the -d option.
Last, if you want to dump the table into an easily parsable format (for a piece of software), you might want to use the -s option which
specifies a character to use as separator. All data fields will be printed out separated by this character only. This allows to use string
parsers to cut down the output lines into tokens by looking for this separator. Fields (lines) will still be delimited by the end-of-line
character. This option produces ASCII tables which are easy to parse for a piece of software but mostly unreadable to human beings.
Notice that dtfits only accepts one single FITS table in input.
OPTIONS
-d Skip information output about the table and column names. Outputs only the table values. Beware that if the FITS file contains sev-
eral extensions, they will all appear one after another, separated only by two blank lines. In that case, it would be preferrable to
keep the complete output and parse out the returned stream to differentiate which data come from where.
-s <char>
Use the character <char> as separator in output. This option is useful if you want to produce a table that should be parsed by a
piece of software (see above description). The separator can only be a single non-null character. To avoid special characters being
interpreted by the shell, it is recommended to provide this character always between simple or double quotes. Example:
dtfits -s '&' table.tfits
If you want to use a special character as separator, such as a tab, use ^V to insert your character, such as:
dtfits -s '^V<TAB>' table.tfits
which means: you type CTRL-V and then the tab key.
SEE ALSO
dfits
FILES
FITS tables are stored into extensions. If there are several tables in a file, they will all be displayed one after another in the same
output stream.
22 Dec 1999 dtfits(1)