Sponsored Content
Full Discussion: UNIX command to pivot data
Top Forums Shell Programming and Scripting UNIX command to pivot data Post 302991165 by vgersh99 on Tuesday 7th of February 2017 10:12:49 AM
Old 02-07-2017
Code:
echo 'a|b|c' | tr '|' '\n'
echo 'a|b|c' | awk -F'|' -v OFS='\n' '$1=$1'

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

pivot

I have a sql table with : Acitvity Date Value ABC 7/11 10 DEF 7/11 98 ABC 7/12 23 DEF 7/12 100 SER 7/12 67 GRH 7/13 123 HJY 7/14 12 I... (4 Replies)
Discussion started by: mukhanj
4 Replies

2. UNIX for Advanced & Expert Users

how to read the data from an excel sheet and use those data as variable in the unix c

I have 3 columns in an excel sheet. c1 c2 c3 EIP_ACCOUNT SMALL_TS_01 select A.* from acc; All the above 3 col shoud be passed a variable in the unix code. 1.How to read an excel file 2.How to pass these data as variable to the unic script (1 Reply)
Discussion started by: Anne Grace
1 Replies

3. UNIX for Dummies Questions & Answers

Validating XSL sheet data in Unix Data file

Dear All, Need your help. In my day to day activities I have to validate/search Excel Sheet data (eg.say Application No. 0066782345) data into the Unix environment file whether the same data is present in that file or not. There are hundreds of records coming in excel file and I am doing grep... (1 Reply)
Discussion started by: ravijunghare
1 Replies

4. UNIX for Dummies Questions & Answers

TWO QUESTIONS...How to create your own command in UNIX server,How to enter data in a file by script

I am a quite newbie on UNIX SCRIPTING...Please help me solving this two questions... 1st Question; I want to create one command that will run a script when anyone use that command on that server... I mean, in the prompt if I put my name 'Rony' it will execute a script called 'rony.sh'. How can... (1 Reply)
Discussion started by: Rony-123
1 Replies

5. UNIX for Advanced & Expert Users

Checking missing data's sequence (shell script | UNIX command)

Dear All members, i have some trouble here, i want to ask your help. The case is: I have some data, it's like: -ABCD1234 -ABCD1235 -ABCD1237 -BCDE1111 -BCDE1112 -BCDE1114 there is some missing data's sequence (the format is: ABCD = name 1234 = sequence). I want to print the... (2 Replies)
Discussion started by: septian.tri
2 Replies

6. Shell Programming and Scripting

Pivot using awk

Hi, I am writing a code to basically pivot the data. awk -v var1="" -v var2="" -v var3="" -v var4="" -v var5="" -v Disp=0\ 'BEGIN {FS=":"; OFS="|";}\ /^Pattern1/ {var1=$2;Disp=0;} \ /^Pattern2/ {var2=$2;} \ /^Pattern3/ {var3=$2;} \ /^Pattern4/ {var4=$2;} \ /^Pattern5/... (5 Replies)
Discussion started by: tostay2003
5 Replies

7. Shell Programming and Scripting

Compare output of UNIX command and match data to text file

I am working on an outage script and I run a command from the command line which tells me the amount of generator failures in my market. The output of this command only gives me three digits to identify the site by. I have a master list of all sites in a separate file, call it list.txt. If my... (7 Replies)
Discussion started by: jbrass
7 Replies

8. Shell Programming and Scripting

Pivot data using awk

Hi My Input is like below DELETE|MPI|AUD_UPD_AGENT|MPISYS INSERT|MPI|AUD_UPD_AGENT|MPISYS SELECT|MPI|AUD_UPD_AGENT|MPISYS UPDATE|MPI|AUD_UPD_AGENT|MPISYS DELETE|MPI|BDYMOD|MPISYS INSERT|MPI|BDYMOD|MPISYS SELECT|MPI|BDYMOD|MPISYS UPDATE|MPI|BDYMOD|MPISYS DELETE|MPI|BDYMOD_DESC|MPISYS... (4 Replies)
Discussion started by: dineshaila
4 Replies

9. UNIX for Beginners Questions & Answers

Data Pivot

Good Day, I have file input 6285296582710|20170509|INDOTEL 6285296835209|20170509|INDOTEL 6285296940311|20170509|INDOTEL 6285297027737|20170509|MULTIFLAG 6285297027737|20170509|DELTA 6285297304373|20170510|INDOTEL 6285297384129|20170510|INDOTEL 6285296940311|20170510|MULTIFLAG... (2 Replies)
Discussion started by: radius
2 Replies

10. Shell Programming and Scripting

Pivot example

Hi all, I am new to shell scripting so pardon me for the questions I will be asking. I was given a task where I have to pivot my data Example Source SGPAPCTUMACCHEA Expected output SGP APC TUM SGP APC ACC SGP APC HEA Can anybody assist me on this?Please use CODE tags as required... (3 Replies)
Discussion started by: redaela
3 Replies
Dis88 disassembles 8088 object code to the assembly language for-
mat used by It makes full use of symbol table  information,  sup-
ports separate instruction and data space, and generates synthet-
ic labels when needed.	It does not support 8087 mnemonics,  sym-
bolic  data segment references, or the ESC mnemonic.  The program
is invoked by: The -o flag causes object code to be  listed.   If
no  outfile is given, stdout is used.  The text segment of an ob-
ject file is always padded to an even address.	In  addition,  if
the  file has split I/D space, the text segment will be padded to
a paragraph boundary (i.e., an address divisible by 16).  Due  to
padding,  the  disassembler may produce a few spurious, but harm-
less, instructions at the end of the text segment.   Because  the
information  to which initialized data refers cannot generally be
inferred from context, the data  segment  is  treated  literally.
Byte  values  (in  hexadecimal) are output, and long stretches of
null data are represented by appropriate .zerow pseudo-ops.  Dis-
assembly  of  the  bss	segment,  on  the  other  hand,  is quite
straightforward, because uninitialized data is all zero by  defi-
nition.   No  data is output in the bss segment, but symbolic la-
bels are output as appropriate.  The output of operands  in  sym-
bolic  form is complicated somewhat by the existence of assembler
symbolic constants and segment override opcodes. Thus,	the  pro-
gram's	symbol	lookup routine attempts to apply a certain amount
of intelligence when it is asked to find a symbol. If  it  cannot
match  on  a symbol of the preferred type, it may output a symbol
of some other type, depending on preassigned (and somewhat  arbi-
trary)	rankings within each type. Finally, if all else fails, it
will output a string containing the address sought as a hex  con-
stant.	For  user  convenience,  the targets of branches are also
output, in comments, as  hexadecimal  constants.   Various  error
messages  may  be  generated  as a result of problems encountered
during the disassembly.  They are listed below
   Cannot access input file   - Input file cannot  be  opened  or
				read
   Cannot open output file    - Output file cannot be created
   Input file not in object format-Bad magic number
   Not an 8086/8088 object file -CPU ID of the file header is in-
				correct
   Reloc table overflow       - Relocation table exceeds 1500 en-
				tries
   Symbol table overflow      - Symbol table exceeds 1500 entries
   Lseek error		      - Input file corrupted (should nev-
				er happen)
   Warning: no symbols	      - Symbol table is missing (use ast)
   Cannot reopen input file   - Input file was removed during ex-
				ecution
Dis88	was  written  and copyrighted by G. M. Harding and is in-
cluded here by permission. It may be freely redistributed provid-
ed  that complete source code, with all copyright notices, accom-
panies any redistribution. This provision  also  applies  to  any
modifications  you  may  make.	You  are  urged  to  comment such
changes, giving, as a minimum, your name and complete address.
All times are GMT -4. The time now is 12:55 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy