Sponsored Content
Top Forums Shell Programming and Scripting Removing Headers and a Column Post 302162688 by Smiling Dragon on Tuesday 29th of January 2008 07:25:24 PM
Old 01-29-2008
Yeah, I had some bugs :/ It should do everything you are after (I hope)

Fixed more bugs in the orginal:
Added \n to the print $1$2 line
Replaced the / symbol in the pagebreak calculation with % (modulo arithmatic)

Edit: Woops, didn't read your request right - I've been removing the first line of each page, not the first 6... Will fix...
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Excel Column Headers

cat ABC.log | egrep "Error 500" >> /tmp/Logs.log egrep "<Mango>.*<.Mango>" Logs.log | sed -e "s/^.*<Mango/<Mango/" | cut -f2 -d">"| cut -f1 -d"<" >> /tmp/temp1.xls egrep "<Apple>.*<.Apple>" Logs.log | sed -e "s/^.*<Apple/<Apple/" | cut -f2 -d">"| cut -f1 -d"<" >> /tmp/temp2.xls print Heading1,... (1 Reply)
Discussion started by: pk_eee
1 Replies

2. Shell Programming and Scripting

Merging of files with different headers to make combined headers file

Hi , I have a typical situation. I have 4 files and with different headers (number of headers is varible ). I need to make such a merged file which will have headers combined from all files (comman coluns should appear once only). For example - File 1 H1|H2|H3|H4 11|12|13|14 21|22|23|23... (1 Reply)
Discussion started by: marut_ashu
1 Replies

3. UNIX for Dummies Questions & Answers

Sort by Column Headers

Hi All, I am new to UNIX can you please help me to sort a file with different columns my file looks like this $ cat gaut.txt UID PID PPID PGID SID C STIME TTY TIME CMD liveuser 3008 2892 3008 3008 0 11:58 ? 00:00:00 gnome-session liveuser 3019 1 ... (8 Replies)
Discussion started by: cgk1983
8 Replies

4. Shell Programming and Scripting

Matching words based on column headers

Hi , Pls help on this. Input file: NAME1 BSC1 TEXT ID 1 MAINSFAIL TEXT ID 2 DGON TEXT ID 3 lOADONDG NAME2 BSC2 TEXT ID 1 DGON TEXT ID 3 lOADONG (1 Reply)
Discussion started by: bha148
1 Replies

5. Shell Programming and Scripting

Transpose field names from column headers to values in one column

Hi All, I'm looking for a script which can transpose field names from column headers to values in one column. for example, the input is: IDa;IDb;IDc;PARAM1;PARAM2;PARAM3; a;b;c;p1val;p2val;p3val; d;e;f;p4val;p5val;p6val; g;h;i;p7val;p8val;p9val; into the output like this: ... (6 Replies)
Discussion started by: popesk
6 Replies

6. Shell Programming and Scripting

Merge column headers and transpose

Hello Everyone! I am new on this forum and this is my first post. I wish to apologize for my, not canonical, English. I would like to solve this problem but I have no clue of how do it!I will be grateful if someone could help me! I have a table like this: gene TF1 TF2 TF3 TF4 gene1 1 2 3 4... (5 Replies)
Discussion started by: giuliangiuseppe
5 Replies

7. Shell Programming and Scripting

Sar -u generates multiple column headers in csv file

Hi All, The below sar -u command generates multiple column headers in csv file Expected output should print column headers only once in the csv file shell script: $cat sar_cpu_EBS.sh #!/bin/bash while ; do sar -u 15 1 | awk '/^/ {print $1,$2,$4,$6,$7}' | tr -s ' ' ',' >>... (6 Replies)
Discussion started by: a1_win
6 Replies

8. Shell Programming and Scripting

Merge csvs with column headers

hello gurus, Somebody must have done this before, I couldn't find anything. Please redirect me if this was solved before, and if not please help. To the problem now, I have multiple csv files (about 1000) which I need to concatenate by column header. The final file should have a superset... (4 Replies)
Discussion started by: abh.kumar
4 Replies

9. Shell Programming and Scripting

Capturing column headers in an array

Hello, I am processing a tab delimited text file and need to grab all of the column headers in an array. The input looks like, num Name PCA_A1 PCA_A2 PCA_A3 0 compound_00 -3.5054 -1.1207 -2.4372 1 compound_01 -2.2641 0.4287 ... (5 Replies)
Discussion started by: LMHmedchem
5 Replies

10. Shell Programming and Scripting

Row bind multiple csv files having different column headers

All, I guess by this time someone asked this kind of question, but sorry I am unable to find after a deep search. Here is my request I have many files out of which 2 sample files provided below. File-1 (with A,B as column headers) A,B 1,2 File-2 (with C, D as column headers) C,D 4,5 I... (7 Replies)
Discussion started by: ks_reddy
7 Replies
PALBART(1)						      General Commands Manual							PALBART(1)

NAME
palbart - BART enhanced PDP8 crossassembler SYNOPSIS
palbart [options]inputfile DESCRIPTION
This manual page documents briefly the palbart command. It is a cross-assembler to for PDP/8 assembly language programs. It will produce an output file in bin format, rim format, and using the appropriate pseudo-ops, a combination of rim and bin formats. A listing file is always produced and with an optional symbol table and/or a symbol cross-reference (concordance). The permanent symbol table can be output in a form that may be read back in so a customized permanent symbol table can be produced. Any detected errors are output to a separate file giving the filename in which they were detected along with the line number, column number and error message as well as marking the error in the listing file. The following file name extensions are used: .pal source code (input) .lst assembly listing (output) .bin assembly output in DEC's bin format (output) .rim assembly output in DEC's rim format (output) .err assembly errors detected (if any) (output) .prm permanent symbol table in form suitable for reading after the EXPUNGE pseudo-op. OPTIONS
A summary of options is included below. -d Show symbol table at end of assembly -h Display help. -l Allow generation of literals (default is no literal generation) Show version of program. -p Generate a file with the permanent symbols in it. (To get the current symbol table, assemble a file than has only a $ in it.) -r Produce output in rim format (default is bin format) -v Display version information. -x Generate a cross-reference (concordance) of user symbols. DIAGNOSTICS
Assembler error diagnostics are output to an error file and inserted in the listing file. Each line in the error file has the form <filename>(<line>:<col>) : error: <message> at Loc = <loc> An example error message is: bintst.pal(17:9) : error: undefined symbol "UNDEF" at Loc = 07616 The error diagnostics put in the listing start with a two character error code (if appropriate) and a short message. A carat '^' is placed under the item in error if appropriate. An example error message is: 17 07616 3000 DCA UNDEF UD undefined ^ 18 07617 1777 TAD I DUMMY When an indirect is generated, an at character '@' is placed after the the instruction value in the listing as an indicator as follows: 14 03716 1777@ TAD OFFPAG Undefined symbols are marked in the symbol table listing by prepending a '?' to the symbol. Redefined symbols are marked in the symbol ta- ble listing by prepending a '#' to the symbol. Examples are: #REDEF 04567 SWITCH 07612 ?UNDEF 00000 Refer to the code for the diagnostic messages generated. BUGS
Only a minimal effort has been made to keep the listing format anything like the PAL-8 listing format. The operation of the conditional assembly pseudo-ops may not function exactly as the DEC versions. I did not have any examples of these so the implementation is my inter- pretation of how they should work. The RIMPUNch and BINPUNch pseudo-ops do not change the binary output file type that was specified on startup. This was intentional and and allows rim formatted data to be output prior to the actual binary formatted data. On UN*X style systems, the same effect can be achieved ing the "cat" command, but on DOS/Windows systems, doing this was a major chore. The floating point input does not generate values exactly as the DEC compiler does. I worked out several examples by hand and believe that this implementation is slightly more accurate. If I am mistaken, let me know and, if possible, a better method of generating the values. HISTORICAL NOTE
This assembler was written to support the fleet of PDP-8 systems used by the Bay Area Rapid Transit System. As of early 1997, this includes about 40 PDP-8/E systems driving the train destination signs in passenger stations. REFERENCES
This assembler is based on the pal assember by: Douglas Jones <jones@cs.uiowa.edu> and Rich Coon <coon@convexw.convex.com> DISCLAIMER
See the symbol table for the set of pseudo-ops supported. See the code for pseudo-ops that are not standard for PDP/8 assembly. Refer to DEC's "Programming Languages (for the PDP/8)" for complete documentation of pseudo-ops. Refer to DEC's "Introduction to Programming (for the PDP/8)" or a lower level introduction to the assembly language. WARRANTY
If you don't like it the way it works or if it doesn't work, that's tough. You're welcome to fix it yourself. That's what you get for using free software. COPYRIGHT NOTICE
This is free software. There is no fee for using it. You may make any changes that you wish and also give it away. If you can make a commercial product out of it, fine, but do not put any limits on the purchaser's right to do the same. If you improve it or fix any bugs, it would be nice if you told me and offered me a copy of the new version. Gary Messenbrink <gam@rahul.net> VERSIONS
Version Date by Comments v1.0 12Apr96 GAM Original v1.1 18Nov96 GAM Permanent symbol table initialization error. v1.2 20Nov96 GAM Added BINPUNch and RIMPUNch pseudo-operators. v1.3 24Nov96 GAM Added DUBL pseudo-op (24 bit integer constants). v1.4 29Nov96 GAM Fixed bug in checksum generation. v2.1 08Dec96 GAM Added concordance processing (cross reference). v2.2 10Dec96 GAM Added FLTG psuedo-op (floating point constants). v2.3 2Feb97 GAM Fixed paging problem in cross reference output. v2.4 11Apr97 GAM Fixed problem with some labels being put in cross reference multiple times. AUTHOR
This manual page was written by Vince Mulhollon <vlm@debian.org>, for the Debian GNU/Linux system (but may be used by others). January 16, 2000 PALBART(1)
All times are GMT -4. The time now is 10:03 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy